Topics

Current Firmware

Jerry Gaffke
 

One problem with libraries is that they change.
Sometimes stuff simply disappears off web. 
Good luck building the original Bitx40 code of Dec 2016 (the etherkit si5351 library has changed).

A good reason for libraries is they can give portability across various processors.
Another is that they allow software to be quickly developed, no need to reinvent how to do stuff
or even figure out how it works.

But for production code, the fewer libraries getting sucked in the happier I am.

Jerry



On Wed, Jun 6, 2018 at 10:30 am, Jack Purdum wrote:
I would start by urging programmers to follow the convention I mentioned earlier, which is to provide the download URL for any non-Arduino libraries on the same line as their #include directive. Then at least you've know where to go to download the required libraries.
 

Arv Evans
 

Jerry

Sounds like a good reason to save the pre-processor output and name it filename.ino
This way you only need the libraries once and can dispense with the #include <library.h>
stuff for future compiles.  You can even check it back into the repository and eliminate
the need for repository based libraries for your project.

Arv
_._


On Wed, Jun 6, 2018 at 11:48 AM Jerry Gaffke via Groups.Io <jgaffke=yahoo.com@groups.io> wrote:
One problem with libraries is that they change.
Sometimes stuff simply disappears off web. 
Good luck building the original Bitx40 code of Dec 2016 (the etherkit si5351 library has changed).

A good reason for libraries is they can give portability across various processors.
Another is that they allow software to be quickly developed, no need to reinvent how to do stuff
or even figure out how it works.

But for production code, the fewer libraries getting sucked in the happier I am.

Jerry



On Wed, Jun 6, 2018 at 10:30 am, Jack Purdum wrote:
I would start by urging programmers to follow the convention I mentioned earlier, which is to provide the download URL for any non-Arduino libraries on the same line as their #include directive. Then at least you've know where to go to download the required libraries.
 

Art Olson
 

Dennis

If you get a hex file use the loader see link below





On Jun 6, 2018, at 1:14 PM, Tom, wb6b <wb6b@...> wrote:

Hi Dennis,

It looks like what you are trying to compile is, the code you would see if you clicked on "view source code" in your browser while looking at the code on GitHub. Of course, it is possible that something was temporary wrong at GitHub when you tried to download the code.

Try this link to download the zip file for the code. https://github.com/afarhan/ubitx4/archive/master.zip

I believe the CEC firmware has compiled HEX files available. There were instructions for how to install a program on Windows that could program an Arduino from the HEX file. In my case, as I have a Mac, it was just easier to compile the CEC software and upload it from the Arduino Sketch. 

Hopefully the number of errors you get, if any, will be simple "not found" errors as Jack mentioned. Those would be the libraries you would install from the "Sketch", "Include Library", "Manage Libraries" dropdown. Jack also points out that libraries can be downloaded directly from URLs, but I think anything needed for the factory firmware would be obtainable using the Sketch user interface.

Hang in there, much of programming and compiling seems counterintuitive. But, once you begin find your way around it starts to make sense. Once it all makes sense you've gone off the deep end and become a real programmer.

Side note: Hmmm. Maybe all those dire warnings about Microsoft and GitHub have so quickly become reality. After all, look at the first error:
"warning: missing terminating ' character
    Microsoft is acquiring GitHub!"

The deal hasn't even closed yet, and here we are...

Tom, wb6b

Dennis
 

Just an update - I was able to load 4.3 onto the Arduino Nano by using the file Gary sent me. I used a Windows 7 machine to accomplish this. I don't think the Mac is well suited for uploading to the Arduino - at least in my shack.

73, Dennis
W7DRW

DJ2AG
 

I’m trying to help you make it run on your Mac and for this have some questions, if you don’t mind.

So you got a hex file or a ino file from Gary and you had to use Windows for uploading or compiling and uploading?
Did you use the Arduino IDE on Windows for this or used the ArduinoBuilder?
It’s  somewhat confusing.

i don’t think it’s a problem with your Mac if compilation fails. A lot of people, including me use Macs for Arduino development without problems. 

First you need to have a proper C ( ino) file, which according to the errors you posted is not the case. You are trying to compile a file with  html content, so as already mentioned before obviously something went wrong with your download. The same file compiled under Windows would als have thrown errors.

Did you use the downloaded  zip file from GitHub or used another method to fetch the files?

73 Armin, DJ2AG

Dennis
 

Hi Armin,

1. The file I used from Gary was an ino file. (he also sent along a hex file, but I couldn't get ArduinoBuilder to work)
2. I originally used the zip file from Github - this file contained several ino files - I didn't (don't) know how to compile them altogether to create one compiled file to upload to the Arduino.
3. I am using Arduino IDE on three different machines.
issue with the mac - I would get a "failed to upload" message. This seems to be a port assignment issue.
issue with the win10 machine - I would get a "failed to upload" message. Again this seems to be a port assignment issue, but I didn't spend the time to try and resolve the issue.
Win 7 machine ran without issue after I properly assigned the port.
I couldn't get Arduino Builder to work on the Mac again I suspect a port assignment issue as within the port pull down menu there were no ports to assign.

My most pressing questions are: 1. how to assign the port on the Mac and 2. how do I compile the several files included in the zip file from GitHub into one combined file for upload.

Thanks for you help,

73, Dennis
W7DRW

Jack, W8TEE
 

Dennis:

For the Win 7 machine, unpack the ZIP file into a temporary directory. With the Arduino IDE (or a text editor), open each INO file until you find the one that holds both the setup() and loop() functions. This file is the "primary" ino file. Let's assume it is named ubitx_20.ino

I would suggest creating a root directory for the software named uBITXCode, probably on the C drive. So you would have:

     C:/uBITXCode

The Arduino compiler DEMANDS that the directory that holds the project code have the exact same name as the primary file name. Therefore, create a subdirectory with that name:

     C:/uBITXCode/ubitx_20

Now, copy ALL of the project files into that new directory:

    C:/uBITXCode/ubitx_20/ubitx_20.ino
                                            ubitx_cat.ino
                                            ubitx_menu.ino
                                            // ...and so on

Now, start the IDE and click the Open menu option and navigate to the directory and double-click on unbitx_20.ino. The IDE will open the project and automatically create tabs for every file in the project, with the primary file being located in the first tab on the left side of the screen. Then just connect your USB cable to the Arduino and your PC, select the proper board (Tools --> Boards) and port (Tools --> port) and you should be ready to compile and upload the project.

Jack, W8TEE



On Thursday, June 7, 2018, 11:13:17 AM EDT, Dennis <dennis@...> wrote:


Hi Armin,

1. The file I used from Gary was an ino file. (he also sent along a hex file, but I couldn't get ArduinoBuilder to work)
2. I originally used the zip file from Github - this file contained several ino files - I didn't (don't) know how to compile them altogether to create one compiled file to upload to the Arduino.
3. I am using Arduino IDE on three different machines.
issue with the mac - I would get a "failed to upload" message. This seems to be a port assignment issue.
issue with the win10 machine - I would get a "failed to upload" message. Again this seems to be a port assignment issue, but I didn't spend the time to try and resolve the issue.
Win 7 machine ran without issue after I properly assigned the port.
I couldn't get Arduino Builder to work on the Mac again I suspect a port assignment issue as within the port pull down menu there were no ports to assign.

My most pressing questions are: 1. how to assign the port on the Mac and 2. how do I compile the several files included in the zip file from GitHub into one combined file for upload.

Thanks for you help,

73, Dennis
W7DRW

Dennis Yancey <bigbluedry@...>
 

Also, once you have the files extracted , it should have created a sub directory. That sub directory name is the same as the main file. Another thing that ishelpful is. If you try to load any .ino file in that directory. IDE, at least in Linux, will load the main file. So, it is hard to not load the correct file. 

Tom, wb6b
 

Hi Dennis,

Regarding the "failed to upload" message.

Both the Mac and many Windows machines need a driver installed to upload to the Raduino Nano board. Here is a somewhat random list of links to drivers I found doing a search of the BITX20 postings. If anyone has had success with these or another link, please chime in.

In some cases people have these drivers on their computers because they have installed software for a product that uses the same USB to Serial chip.

https://github.com/adrianmihalko/ch340g-ch34g-ch34x-mac-os-x-driver 
http://esp32.net/usb-uart/
http://www.wch.cn/download/CH341SER_ZIP.html
http://www.cesareriva.com/usb-to-serial-converter-hl-340-drivers/
CH340 Drivers for Windows, Mac and Linux.

Tom, wb6b