ict.ken.be

Delivering solid user friendly software solutions since the dawn of time.

Playstation 

Categories: Notes

Glossary

  • ELF: Extensible Linking Format is the file format commonly used for Playstation binaries. Eg. BOOT.ELF
  • ESR : This is not an abbriviation but a way to load dvd copies. I prefer using network loading with OPL as the whole point is to not only spare your dvd roms but also your playstation laser. Remeber that you need to patch your dvd iso before burning it.
  • FMCB : FreeMcBoot allows for booting your playstation into software installed onto your memory card. Which allows you to copy software from a usb-drive. It's kind of catch-22 as to be able to install the initial software on your memory card you need to have a card that has FMCB installed. If you can't buy an initial copy there are tricks to exploit the dvd loading and install it like this, but that's kind of tedious.
  • GSM : Graphics Synthetizer Mode Selector you might need to get some specific games working. You can learn about the workings, but it's mostly enough to just lookup the mode in the tables at PS2-home.
  • OPL : Open PS2 Loader, far the easiest way to manage playing games over the network. Doesn't work for all games, but use it whenever possible to spare your ps2 laser.
  • SMB : Server Message Block aka Samba allows you to setup a network between your PS2 and pc.
  • SMS : Simple Media System allows for playing videos. Nice, but not very useful since we all have tablets now.
  • MagicGate : Brand of original PS2 memory cards that is needed to run FMCB, watch out as often the bigger ones are fake and will not work. Use an original 8MB for your first experiments.
  • uLaunchElf : Your basic file browser that allows you to run executables.

Configuration

Some screenshots of playstation 2 fmcb and opl settings over network.

References

Reactjs 

Categories: Reactjs

Just some basic react cheatsheet

  • import React from "react"
  • use an expression to put comments
{/* you can use this to commend inside your jsx */}
  • useĀ a fragment if you want to quickly include an exiting html structure with more then one element at the root
<>
<h1>Some header<h1>
<h2>Some subheader<h2>
</>

Error: endpoint data missing from graphql config when using gatsby with vscode 

Categories: Gatsbyjs GraphQL VSCode

Most likely you installed the GraphQL extension for VSCode to add syntax highlighting to your graphql queries. Then you noticed the codelens 'Execute Query' and got one of the following errors:

  • Error: endpoint data missing from graphql config
  • ConfigNotFoundError: ".graphqlconfig" file is not available in the provided config directory

To solve this issue, you need to create a .graphqlconfig file in your project root folder.

Tricky part is figuring out what you need to put in there for using Gatsby.

So here is an example:

{
  "name": "Gatsby Schema",
  "schemaPath": "schema.graphql",
  "extensions": {
    "endpoints": {
      "Remote GraphQL Endpoint": {
        "url": "http://localhost:8000/___graphql",
        "headers": {
          "user-agent": "JS GraphQL"
        },
        "introspect": true
      }
    }
  }
}

Stop Teamcity build when other build starts 

Categories: Windows

Most likely you want to stop running your long end-2-end tests when a new deployment is ready.
You will lose the correlation between when the error happened, but at least you can move on.
The easiest way to do this in Teamcity (as there is no support at this writing),
is to add an additional step before the deployment build configuration using the following powershell script.

So you basically cancel the test build configuration when the deployment starts.

$buildConfigurationId = '%E2ETestBuildConfigurationId%'
If (![string]::IsNullOrWhitespace($buildConfigurationId)) { 
    Write-Host "Finding test builds"
    $user = '%system.teamcity.auth.userId%'
    $pass = '%system.teamcity.auth.password%'
    $pair = "${user}:${pass}"
    $bytes = [System.Text.Encoding]::ASCII.GetBytes($pair)
    $base64 = [System.Convert]::ToBase64String($bytes)
    $basicAuthValue = "Basic $base64"
    $headers = @{ Authorization = $basicAuthValue; "Content-Type" = "application/xml" }
    $response = Invoke-WebRequest -Uri "http://teamcity.conseur.org/app/rest/builds?locator=buildType:($buildConfigurationId),state:queued" -Method GET -Headers $headers
    $postParams = "<buildCancelRequest comment='Build was canceled because of new deployment.' readdIntoQueue='true' />"
    Foreach($buildId in ([xml]$response.Content).builds.build.id) 
    {
        Write-Host "Cancel queued buildId: $buildId"
        Invoke-WebRequest -Uri "http://teamcity.conseur.org/app/rest/buildQueue/id:$buildId" -Headers $headers -Method POST -Body $postParams
    }
    $response = Invoke-WebRequest -Uri "http://teamcity.conseur.org/app/rest/builds?locator=buildType:($buildConfigurationId),state:running" -Method GET -Headers $headers
    $postParams = "<buildCancelRequest comment='Build was canceled because of new deployment.' readdIntoQueue='false' />"
    Foreach($buildId in ([xml]$response.Content).builds.build.id) 
    {
        Write-Host "Cancel running buildId: $buildId"
        Invoke-WebRequest -Uri "http://teamcity.conseur.org/app/rest/builds/id:$buildId" -Headers $headers -Method POST -Body $postParams
    }
}
Page 2 of 42 << < 1 2 3 4 5 6 7 8 9 10 20 40 > >>