Shop OBEX P1 Docs P2 Docs Learn Events
p2load: A Loader for the Propeller II - Page 11 — Parallax Forums

p2load: A Loader for the Propeller II

15678911»

Comments

  • David BetzDavid Betz Posts: 14,511
    edited 2013-04-29 06:48
    Sapieha wrote: »
    Hi David.

    Have You PASM code to that You can post.

    Thanks
    No, the support is in the C runtime library. You could still write your drivers in PNut using PASM but load them as blobs from C code that could manage reading data from an SD card and writing it to SDRAM. You'd need a DE2-115 board for that of course since you'd need at least two COGs.

    Edit: Actually, the low-level sector I/O code is written in assembly using GAS. It's in the propgcc/lib/drivers directory of the propgcc sources. The filename is sd_driver2.s.
  • SapiehaSapieha Posts: 2,964
    edited 2013-04-29 07:04
    Hi David.

    Thanks

    David Betz wrote: »
    No, the support is in the C runtime library. You could still write your drivers in PNut using PASM but load them as blobs from C code that could manage reading data from an SD card and writing it to SDRAM. You'd need a DE2-115 board for that of course since you'd need at least two COGs.

    Edit: Actually, the low-level sector I/O code is written in assembly using GAS. It's in the propgcc/lib/drivers directory of the propgcc sources. The filename is sd_driver2.s.
  • David BetzDavid Betz Posts: 14,511
    edited 2013-04-29 07:12
    Sapieha wrote: »
    Hi David.

    Thanks
    I guess I should write an example of using one of Baggers' video drivers from a C program to provide a template for people to use. Also, I'd have to write a C interface to Chip's SDRAM driver but that should be pretty easy.
  • BaggersBaggers Posts: 3,019
    edited 2013-04-29 07:21
    I've not set up PropGCC yet, so an example to start from would be ace! :D
  • David BetzDavid Betz Posts: 14,511
    edited 2013-04-29 09:02
    Baggers wrote: »
    I've not set up PropGCC yet, so an example to start from would be ace! :D
    I'll work up an example but unfortunately I can't do it until Sunday. I'm traveling tomorrow through Saturday night.
  • BaggersBaggers Posts: 3,019
    edited 2013-04-29 11:04
    David Betz wrote: »
    I'll work up an example but unfortunately I can't do it until Sunday. I'm traveling tomorrow through Saturday night.

    Thanks, and no worries :D
    It'll give me time to get PropGCC installed etc. lol
  • Cluso99Cluso99 Posts: 18,069
    edited 2013-04-29 20:41
    David,
    Is the load mechnism the same on P1?
    Why I ask is I wonder if your P2Load could be modified to also work on the P1? The features to load multiple files at various locations is a nifty feature.
    I am not asking you to do it, just wondering how much work is likely involved.
  • David BetzDavid Betz Posts: 14,511
    edited 2013-04-30 03:51
    Cluso99 wrote: »
    David,
    Is the load mechnism the same on P1?
    Why I ask is I wonder if your P2Load could be modified to also work on the P1? The features to load multiple files at various locations is a nifty feature.
    I am not asking you to do it, just wondering how much work is likely involved.
    I'm already thinking about that but I'm traveling for a few days so I won't be able to do much until Sunday.
  • TubularTubular Posts: 4,622
    edited 2013-05-18 15:04
    David

    Just wanted to say a big thankyou for your efforts on p2load. -w option worked straight up. Having just moved back onto some p2 software development, and my head stuck in 'pasm mode' where everything requires thinking and iteration, having something that just worked was extremely welcome !

    thanks again
    Lachlan
  • David BetzDavid Betz Posts: 14,511
    edited 2013-05-18 19:39
    Tubular wrote: »
    David

    Just wanted to say a big thankyou for your efforts on p2load. -w option worked straight up. Having just moved back onto some p2 software development, and my head stuck in 'pasm mode' where everything requires thinking and iteration, having something that just worked was extremely welcome !

    thanks again
    Lachlan
    Thanks for the compliment! I'm glad it worked well for you.
  • SapiehaSapieha Posts: 2,964
    edited 2013-05-21 10:44
    Hi David.


    I have dumb question --- It is possible You made so p2load unload itself after entering Terminal mode in CMD window.

    Else it needs even in that mode?
  • David BetzDavid Betz Posts: 14,511
    edited 2013-05-21 10:49
    Sapieha wrote: »
    Hi David.


    I have dumb question --- It is possible You made so p2load unload itself after entering Terminal mode in CMD window.

    Else it needs even in that mode?
    p2load can't unload itself when entering terminal mode with -t since it implements the terminal mode handler. Are you asking if you can pass terminal handling off to another terminal emulator? You should be able to do that by just leaving -t off and starting the terminal emulator after p2load completes. You'll need to have some sort of delay in your program before it starts writing to the terminal though so you won't miss some of the output when switching from p2load to the terminal emulator.
  • SapiehaSapieha Posts: 2,964
    edited 2013-05-21 10:56
    Hi David.

    Thanks -- for answer
    Now I understand
  • David BetzDavid Betz Posts: 14,511
    edited 2013-07-01 06:04
    I'm bumping this thread because it is older than the default cutoff for messages in this forum.
  • rjo__rjo__ Posts: 2,114
    edited 2013-09-21 19:26
    Good Evening David

    I have the p2load that is part of SimpleIDE 0.9.43.

    On a Mac, 10.6.8, from the terminal, when I enter > p2load -?, I get an "illegal instruction."
    I think I have everything sorted correctly, because when I enter > propeller-load -? I get a usage statement. Since propeller-load and p2load are in the same directory, it looks to me p2load isn't working.
    Thanks

    Rich
  • David BetzDavid Betz Posts: 14,511
    edited 2013-09-21 20:36
    rjo__ wrote: »
    Good Evening David

    I have the p2load that is part of SimpleIDE 0.9.43.

    On a Mac, 10.6.8, from the terminal, when I enter > p2load -?, I get an "illegal instruction."
    I think I have everything sorted correctly, because when I enter > propeller-load -? I get a usage statement. Since propeller-load and p2load are in the same directory, it looks to me p2load isn't working.
    Thanks

    Rich
    I don't think p2load will run under Snow Leopard (10.6). I've only tested it on Mountain Lion and a long time ago on Lion.
  • rjo__rjo__ Posts: 2,114
    edited 2013-09-23 20:05
    Well... that didn't go very well. I tried to use my American Express debit card... and Apple doesn't accept American Express. No joke.
    I'll have to wait until my karma brings me close to an Apple outlet:)
  • TubularTubular Posts: 4,622
    edited 2014-05-06 21:28
    Just found an issue using p2load with newer DE0 firmwares... getting an "error: packet handshake failed" towards the end of loading

    I went back to an earlier firmware, March 2013, and it loaded no problem. Then moved forward again to the later firmware, and it reboots and works fine.

    Nothing to fix really, just putting notes here for when someone else needs the same workaround. That includes me, a few months down the track, when I've forgotten how to do it
  • David BetzDavid Betz Posts: 14,511
    edited 2014-05-06 21:32
    Tubular wrote: »
    Just found an issue using p2load with newer DE0 firmwares... getting an "error: packet handshake failed" towards the end of loading

    I went back to an earlier firmware, March 2013, and it loaded no problem. Then moved forward again to the later firmware, and it reboots and works fine.

    Nothing to fix really, just putting notes here for when someone else needs the same workaround. That includes me, a few months down the track, when I've forgotten how to do it
    Thanks for the bug report. I didn't even know anyone was using p2load anymore. I've kind of been in a holding pattern waiting for some relatively final information about P1+ or P2 or whatever it is called now before updating PropGCC and the various other utilities including p2load. I'll watch for that problem when I finally get back to P2 work.
  • TubularTubular Posts: 4,622
    edited 2014-05-06 22:04
    Yeah, fast heading to the pointy end of the project, hence making programs permanent (flash not ram), documenting, etc

    Completely understand holding off doing updates, especially given the state of play right now.
  • TubularTubular Posts: 4,622
    edited 2015-06-22 15:40
    If anyone needs the latest p2load code, its now on the parallax github over here
    https://github.com/parallaxinc/propgcc/tree/master/p2load
Sign In or Register to comment.