aldras I’ve updated that page with a note underneath. I actually mentioned the issue in the Mac setup section. So I just copied that over. Thanks!

    Reporting back on progress here, am beginning to use the Feather nRF9160 in the development platform so I went to program it and tried many times with the bootloader.

    Not knowing if it was a pin routing issue or some other issue I tried quite a few different pin mapping combinations (for UART2) but could not get any response after loading with the bootloader.

    Of course I didn’t notice the fine print “IMPORTANT: updates above 192kB will not work with the current version of the bootloader. Examples like the asset_tracker require a programmer.” on the page
    https://docs.jaredwolff.com/nrf9160-programming-and-debugging.html

    It appears the program I am attempting to load, serial lte modem, is about 202Kb in side, just above that limit. Pulled out the nRF9160DK and loaded it with nrfjprog, but in doing so I wiped out the bootloader (oops). I will try to recover it later, but the good news is I got the pin layout fixed for UART2 so I would like to report some things about it.

    I am using the following two pins for UART2 communication and here is the routing that I discovered.
    The GPIO numbers appear to refer to the actual GPIO numbers on the MCU, so P0.03 is 3, etc, and it appears to be a little different than the silkscreen numbers.

    Here is the pin mapping from the overlay file (circuitdojo_feather_nrf9160ns.overlay):

    &uart1 {
    	status = "okay";
    
    	current-speed = <115200>;
    	tx-pin = <0>;
    	rx-pin = <2>;
    };
    
    &uart2 {
    	compatible = "nordic,nrf-uarte";
    	//current-speed = <921600>;
    	current-speed = <115200>;
    	// for CTS  RTS support
    	/*
    	tx-pin = <4>;
    	rx-pin = <2>;
    	rts-pin = <3>;
    	cts-pin = <0>;
    	hw-flow-control;
    	*/
    
    	// without CTS RTS support
    	tx-pin = <3>; // Feather nRF9160 D7 (as marked on the silkscreen)
    	rx-pin = <1>; // Feather nRF9160 D5 (as marked on the silkscreen)
    };

    This appears to follow the Actinius Icarus, however I never was able to find the schematics for the Icarus. Something that I would like to have if anyone knows where to get them. I can’t find it on their website, is it buried?

    Anyway, this time around I ran into those two issues, one with the pin mapping, and the other with the bootloader loading. It appeared to load correctly but did not do anything when reset. For reference here are the two commands I used, one for the bootlaoder, the other for nrfjprog, for reference.

    I am also going to attach the two bin files here for you to look at. You should receive serial output on the two pins D5 and D7 upon powerup/reset, nothing will come through the USB connection. Baud rate is 115200.

    /opt/nordic/newtmgr conn add serial type=serial connstring=‘dev=/dev/tty.SLAB_USBtoUART,baud=1000000’
    /opt/nordic/newtmgr -c serial image upload build/zephyr/app_update.bin

    /usr/local/bin/nrfjprog -f NRF91 –program build/zephyr/merged.hex –sectorerase

    The compiled project, and all related is here, nRF SDK version 1.4.99-dev1.
    https://www.drassal.net/filestore/serial_lte_modem_circuitdojo_feather_nrf9160_20210128.zip
    (Still can’t get a file to upload, dragging it into here just copies the text of the filename it seems)
    If you would like to look, see if you can get the file build/zephyr/app_update.bin to work with the bootloader. Confirmed mixed.bin works with nrfjprog. No rush on this though, since I have a work around now with nrfjprog.

    By the way, I really do like this antenna, nice find!
    Need to do some more testing but this flexible LTE antenna is really neat.

    Next bump I ran into.
    I wanted to power the nRF9160 from one of the header pins, I don’t want to push 3V3 through the 3V3 pin since I am not sure the Feather M0 that I am using can handle the load of the nRF9160. What I wanted to do is tie the two “USB” pins together, and I noticed there is a diode that prevents powering FROM the USB pin, from the direction of the diode it only OUTPUTS the USB power from the nRF9160’s USB connector to the USB pin on the header.

    Note, USB pin refers to JP2 pin 3, 5V0 tagged on the schematic.

    What I resorted to is using a micro USB connector and plugging it in, this connector is connected to the “USB” pins on the Feather M0 to power the Feather nRF9150’s 3V3 regulator.

    Not sure if it is a good idea to remove that diode, or maybe provide a couple pads on the bottom to solder bridge to bypass the diode if someone wants to backfeed power into the “USB” pin on the header to provide power to the Feather nRF9160’s 3V3 regulator.

    Correct me if I am wrong here, but it appears the only way to power the Feather nRF9160’s 3V3 regulator is through the micro USB connector (or battery connector). I don’t dare feed 5V0 into that battery connector, I don’t think the charging IC will be happy with me.

      One more note, the “enable” pin, JP2 pin 2, also can’t be tied to the Feather M0, it might be opposite to the function of the M0’s enable pin. It appears to cut power, I didn’t really investigate this, I just removed the connection from the Feather nRF9160 to the Feather M0 on the “enable” pin.

      More and more I am isolating more pins, might just be better to fully isolate the two boards and only connect the needed power, reset, and UART pins…

      If it is not apparent already, I am using one of the Feather Tripler boards…
      https://www.adafruit.com/product/3417

        Was running into some funny problems (nRF9160 self-resetting for some reason), so I went ahead and isolated all pins except the necessary power, reset, and UART pins. This is the better way to do it anyway so I don’t have signals traveling between the MCUs that I am not sure about.

          This is a reply to the post in https://community.jaredwolff.com/d/66-issue-entering-bootloader-in-new-v2-board asking about the JPEG encoding. I started to type this reply there and realized it might be better to have it here. Left a link there for it directing to here.

          If you want to get setup I do have something kinda working, but with HTTP only, no HTTPS support yet.

          I basically found some project of someone who made a JPEG compressor for M0 (and works with M4).
          The M4 is not really optimized for this (takes a few seconds for a 160×120 color image), but I think if the FPU and some hardware support is combined it will work out faster.

          Need to hold the whole raw image in SRAM (or external memory) for the JPEG compression, it jumps around the data while calculating things. A 160 × 120 image comes in at 38400 (160 * 120 * 2) bytes. The resulting JPEG comes in under 10000 bytes, plus some more SRAM used by the JPEG encoding engine itself. I wanted to do 320×200 but it takes more like 128000 SRAM for the raw image, and with the M4 having only 192k SRAM this does not look like it will work. Adding some external SRAM might work, but external SRAM access time will be slow, if you got any ideas it be cool to even be able to do a full 640×480 image!

          Give me a little time to get organized and I will get a zip package setup and uploaded for ya to look at soon.

          Here is what you need, if you have it already great!
          If not, maybe you can sub some other things.
          I will work on getting a guide made soon.

          K2AAE
          Oh thanks, I will keep those in mind.
          My attention switched for a moment over to the ESP32 series, since thats what someone at work wants to work with, I have feelings in both directions with the ESP32 line, mostly reliability concerns if its used in a production environment, however the ESP32-CAM (easy to find on Amazon) has 4MB of PSRAM, plus it has some kind of hardware support for JPEG compression.

          I get a fully compressed JPEG image from the camera’s buffer somehow, it has to have some hardware assistance for how “instant” the JPEG image is available.

          This is another project I will post up soon, it is related to this since its still using the nRF9160 to push the image data to the web, however with the ESP32-CAM I can get a nice 1600 × 1600 image that is around 100k, give or take some bytes depending on the compression. It takes a few seconds to upload but the ESP32-CAM is nice in the way the JPEG is already done for you.

            aldras Hardware JPEG codec ST AN4996 app note coupled with that MAX display which is daylight readable would be fun.

              I have a partially completed guide up on my blog site using the ESP32-CAM and the Feather nRF9160 to upload JPEG images to a PHP script on a webserver. There are images and source code available. It is using Arduino with the TinyGSM library. The required nRF9160 precompiled firmware .hex files are also linked there with version for JTAG nrfjprog programming and also bootloader programming (if the bootloader will load load the large file).

              Once I get the guide more towards completion Ill get some pictures and other information up in this thread soon. A lot of details are really really lacking right now, but wanted to get the project source files up for those interested.

              https://www.drassal.net/wp/index.php/2021/02/03/nrf9160-esp32-cam-jpeg-image-uploader-through-lte/

              Still working on the M4 version of this project, and working on better TinyGSM support.

                Just pushed an update for Arduino TinyGSM library with the updated ESP32-CAM example.
                There are detailed instructions on how to hook things up at the top of the example sketch code.
                It will show up on the examples menu for TinyGSM.

                https://github.com/aldras/TinyGSM/tree/nrf9160_dev

                Just remember to set your server address where www.yourServer.net is and remember your APN authentication information. ESP32-CAM board are plentiful and cheap on Amazon.com, but I would buy a few incase you end up with a bad one (most are in the range of $10-$20 each depending on supplier), I have run into a bad one, and another board that the “brownout” detect is kinda finicky.

                This should be more stable and works with the fixes done to the TinyGSM nRF9160 support.
                The prebuilt firmware is in the example folder for the examples/HttpClient_nrf9160_adafruit_m0_m4 example project.

                The updated M4 camera example is coming soon, still trying to get all the code organized.

                Terms and Conditions | Privacy Policy