Raspberry Pi IoT In C - VS Code Remote C |
Written by Harry Fairhead | ||||
Monday, 05 October 2020 | ||||
Page 3 of 3
If you want to make sure that you have all of the ARM headers for your program you can enter and run the following task: { "label": "copyARMheaders", "type": "shell", "command": "mkdir ${workspaceFolder}/include/; scp -r ${config:sshUser}@${config:sshEndpoint}: /usr/include ${workspaceFolder}/include/ ", "problemMatcher": [], "presentation": { "showReuseMessage": true, "clear": true } } This copies all of the headers to a new include folder. You will also need to add: #define __ARM_PCS_VFP to the start of some of your programs to make all of the spurious intelligent errors go away. This symbol is defined by the compiler at run time to select hardware or software floating point operations. Programs that use headers that depend on the hardware specification generate errors on the local machine as they don’t know the configuration. Notice that none of this has any effect on the program that runs on the remote machine it simply suppresses errors that you see on the local machine as VS Code attempts to find pre-compile errors. The complete tasks.json is: { "version": "2.0.0", "tasks": { "label": "copyToRemote", "type": "shell", "command": "scp -r ${fileDirname} ${config:sshUser}@ ${config:sshEndpoint}:${config:remoteDirectory}/", "problemMatcher": [], "presentation": { "showReuseMessage": false, "clear": true } }, { "label": "copyHeader", "type": "shell", "command": "mkdir ${workspaceFolder}/headers/ ; scp -r ${config:sshUser}@${config:sshEndpoint}: ${config:header} ${workspaceFolder}/headers/ ", "problemMatcher": [], "presentation": { "showReuseMessage": false, "clear": true } }, { "label": "buildRemote", "type": "shell", "command": "ssh ${config:sshUser}@ All of the files can be downloaded from iopress.info. Raspberry Pi And The IoT In C Second EditionBy Harry FairheadBuy from Amazon. Contents
<ASIN:1871962633> <ASIN:B08KLNT2JC> To be informed about new articles on I Programmer, sign up for our weekly newsletter, subscribe to the RSS feed and follow us on Twitter, Facebook or Linkedin.
Comments
or email your comment to: comments@i-programmer.info
|
||||
Last Updated ( Monday, 05 October 2020 ) |