Shop OBEX P1 Docs P2 Docs Learn Events
Programming Propellers from iPad - Page 8 — Parallax Forums

Programming Propellers from iPad

1568101118

Comments

  • David BetzDavid Betz Posts: 14,516
    edited 2013-11-04 12:43
    jazzed wrote: »
    Essentially, yes. USB HUBs with appropriate software running on any old Wifi enabled PC is what I meant.

    Having a Propeller Serial Server is a good demo of Propeller power though.

    There is lots of utility in having something like a WiFly or XBee on board the ActivityBoard/Bot though. Being able to wirelessly drive a bot around is a ton of fun.
    I guess I have a few XBee modules so I could try this myself without even buying anything new. :-)
  • jazzedjazzed Posts: 11,803
    edited 2013-11-04 13:11
    David Betz wrote: »
    I guess I have a few XBee modules so I could try this myself without even buying anything new. :-)
    This might bee a starting point: http://www.parallaxsemiconductor.com/an007

  • Invent-O-DocInvent-O-Doc Posts: 768
    edited 2013-11-04 14:30
    I think that wireless programming of the bots is necessary. It makes things much simpler for the students and makes a central programming computer unobtrusive. I saw a demo two years ago at UPENE where multiple running prop bots were dynamically reprogrammed with 12 blocks. This memory has really stuck with me because the impression it left was so powerful.
  • tdlivingstdlivings Posts: 437
    edited 2013-11-04 17:03
    Interesting concept from Microsoft app runs on iPad
    http://www.macrumors.com/2013/10/17/microsoft-launches-remote-desktop-apps-for-mac-and-ios/

    R
    emote desktop is interesting idea.
    Not saying Microsoft or Mac or Linux is choice for Class Lab Server

    Something to think about
    Each student is running an instance of a VM on the Lab Server and
    the server is running an instance of SimpleIDE, which is now being
    executed from an iPad over the air. Maybe call it ServerIDE this time.

    Reading Steve's post on loading the code using XBEE. ServerIDE would
    need to send the text file, an S record style file to an XBEE which sends the
    text to the XBEE doing the loading of the code.

    Taking a look at Remote Desktop API's to see how they do it might be a good
    exercise in planning what to do.

    Not saying Windows being executed from an iPad is the way to go but looking
    at what they did is and how well it works could be an education for planning

    On the subject of Rasberry Pi I am not sure there is enough resources on a Pi
    for it to be a server for several students at a time. I am not an expert but it just
    seems to small to me.

    Tom
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2013-11-04 17:23
    Remote desktops can exhibit some latency, which makes interactive chores like keying and editing text a bit annoying. 'Might be worth checking out, though.

    -Phil
  • jazzedjazzed Posts: 11,803
    edited 2013-11-04 19:03
    Remote desktops can exhibit some latency, which makes interactive chores like keying and editing text a bit annoying.
    This is true especially if the network connection is slow or the server is clunky (20+ virtual desktops on an RPi? LOL).

    I use VNC all the time with my Mac Mini. The experience could be better, but VNC is much more convenient than a KVM (among other things ;) ).

    Honestly I think a Javascript editor and spin compiler would be better.
  • potatoheadpotatohead Posts: 10,261
    edited 2013-11-04 19:14
    Is there an X server for iPad?

    If so, a Pi could do 8-16 students easy over X. I ran a CAD training room for years on an IRIX server with about double the RAM on the Pi. Client machines ran X, and were a mix of PC, Linux, etc...
  • Don MDon M Posts: 1,652
    edited 2013-11-04 19:29
    Rayman wrote: »
    Something seems wrong to me about this idea of using a Raspberry Pi with a room full of iPads and ActivityBots...
    I'm a fan of Raspberry Pi (I've got one in a big pile of other cool stuff I buy and then don't have time for...), but I think they're most useful for people with not a lot of money...
    If these kids have iPads and ActivityBots, I don't think that cost is their primary motivation. I'd think they were looking for the best they can buy...

    Rayman- I think you have the wrong idea here. Most likely the schools have purchased these IPads etc. Why? Because they think that Apple is the way to go. I think you'll find that most schools that have these don't necessarily have wealthy kids using them. It's usually because someone or group of someone's in the faculty think that that's what they should have.

    Most likely it's the local taxpayers paying for this equipment.
  • David BetzDavid Betz Posts: 14,516
    edited 2013-11-04 20:09
    jazzed wrote: »
    [Honestly I think a Javascript editor and spin compiler would be better.
    Isn't Parallax trying to concentrate on C for their educational offerings? Is a Spin compiler really what they're looking for?
  • jazzedjazzed Posts: 11,803
    edited 2013-11-04 20:48
    David Betz wrote: »
    Isn't Parallax trying to concentrate on C for their educational offerings? Is a Spin compiler really what they're looking for?

    The thread title is Programming Propellers :)

    I forgot about that other aspect.
  • Heater.Heater. Posts: 21,230
    edited 2013-11-05 00:42
    David,
    Isn't Parallax trying to concentrate on C for their educational offerings? Is a Spin compiler really what they're looking for?
    The solution presented by myself and others here can handle C as well. And any other language.

    a) The editor runs in the browser. It's a javascript thing. Perhaps based on the Cloud 9 web IDE or the ACE in browser editor. I'm sure there are other options that I don't know about but those two work well.

    b) Compilation of Spin, C or whatever happens on the server.

    c) The resulting binaries are programmed to the Prop via serial/USB link from the server.

    d) If there is one server per device like a Raspberry Pi per student then direct serial/USB connection is the way to go. If there is a single central server, need not be a Pi, some wireless links to the Props are required. Solutions have been suggested.

    e) Following programming a "serial" link is open between the Prop and the users browser, for an in browser terminal or data acquisition application. Websockets would be ideal for this.

    Somebody here was wondering if the humble Pi was up to the job of acting as such a server for a classroom full of students. I'm sure that it is. It only has to serve up the WEB IDE pages occasionally as these are "web apps" that don't require constant page loading. Compiling programs for the Prop is pretty quick as they are generally not very big. Even in a big class room there are not going to be many compilations happening at the same time. The Pi's memory may be a limitation and I might think about arranging to do only one compilation at a time.
  • RaymanRayman Posts: 14,659
    edited 2013-11-05 01:32
    was just googling "ipad school robot" and found this:
    http://appsineducation.blogspot.com/2013/01/idevices-controlling-robots-in-classroom.html where sphero is the first thing they list... Hey, it's not just me...

    I'm thinking you'll want to be able to control your robot with the iPad as well as program it...
    For that to happen, I think you'll need a Bluetooth connection (or maybe wifi).

    Wonder if the iPad is too big to mount right on top of an ActivityBot, like they do with the iPhone...

    RovingNetworks has Bluetooth solutions that work with iPad. I see they've been bought out by MicroChip...
    Unfortunately, looks like you need to register with Apple and buy their authentication chips to make it work:
    http://ww1.microchip.com/downloads/en/DeviceDoc/RN-41_42-APL-PB_v1_2r.pdf

    Actually, the Sphero and company aren't really what I would call "robots"... They're really just remote controlled vehicles...
    But, I think it would be nice to have a product that would let you both remote control and remote program for autonomous operations...
  • BeanBean Posts: 8,129
    edited 2013-11-05 02:21
    Rayman wrote: »
    was just googling "ipad school robot" and found this:
    http://appsineducation.blogspot.com/2013/01/idevices-controlling-robots-in-classroom.html where sphero is the first thing they list... Hey, it's not just me...
    .

    Nice link Rayman, I noticed that all the low-cost products use an audio-to-infrared link... Hey, it's not just me... ;)

    Bean
  • RaymanRayman Posts: 14,659
    edited 2013-11-05 02:59
    Well, you're right... Maybe that's not such a bad solution...

    Could suffer from interference though with a lot of them though, right?
    Also, I imagine you'd have to keep the dingus pointed at the robot for it to work...
  • T ChapT Chap Posts: 4,223
    edited 2013-11-05 07:22
    Can an iPad generate a binary or .eeprom? Or is that the problem here... that the iPad can only allow for writing code, but it does not have a compiler to generate a file for the Prop?
  • David BetzDavid Betz Posts: 14,516
    edited 2013-11-05 07:27
    T Chap wrote: »
    Can an iPad generate a binary or .eeprom? Or is that the problem here... that the iPad can only allow for writing code, but it does not have a compiler to generate a file for the Prop?
    In theory it should be possible to port PropGCC to the iPad but I suspect it would require a huge effort. The Spin compiler would probably be a lot easier. However, the idea of a compile and download server would be a lot easier to achieve. There still remains the question of how to control the ActivityBot once the code is loaded and running. We'd have to try it to find out if the latency was too great going indirectly through the download server.
  • T ChapT Chap Posts: 4,223
    edited 2013-11-05 07:56
    Here is my suggestion. Either a dedicated PC Server compiler programmer, or a dedicated module that can read a text file and compile and program. Then, use a Nordic nRF24L01+ for the communication from the iPad to the Robot. This requires the Apple Authentication IC, and the simplest to implement is the Roving Networks RN42 APL version. I have talked to Apple and Roving about this before and my understanding is that this is ideal for iPad serial i/o. Parallax would have to enroll in the Apple MFI. Which can take weeks or a month. Once enrolled, you can buy the Roving Networks APL products and be up and running with their development board. But, Roving will not set the products without the Apple license.

    As much as a hassle as Apple makes it to get inside their system to get the Authentication IC, it is worth it to get behind the wall. I got enrolled, but it takes some time and effort. Nick at Roving Networks(now Micro) was a great resource for info on how to do this.
    468 x 633 - 72K
  • mindrobotsmindrobots Posts: 6,506
    edited 2013-11-05 08:01
    <GRUMBLE>
    Dear Parallax,

    I've just purchased an ActivityBOT. It's a wonderful kit which I've assembled and gone through the LEARN exercises with. Now I'm ready to remotely control it from my PC. Can you please point me to the kit I need to purchase and the software I need to run to achieve this?

    Sincerly,

    Hap E. Customer"

    "Dear Parallax,

    I have a ActivityBOT which I'm really enjoying programming and learning about. Now, I'm ready to program it remotely from my PC (currently running Debain OSX 8). Can you give me the part number of the accessory kit I need to purchase and point me to the PC software I would use for this so I can start working with it while my accessory kit is in the mail.

    Yours in Robotics,
    Igotta Pointe"

    </GRUMBLE>

    Guys,

    Don't we need to walk before we run, here?

    It will be a big step to provide a browser based IDE for PropGCC and Spin that can program a Propeller DIRECTLY connected to the "server"

    Since I can't even purchase a Parallax sanctioned and packaged that supports remote (wireless) operation and programming of an ActivityBOT, how can we sincerely address anything tangible as a possible software/appliance solution? There are many ways to accomplish the task and as hobbyists, we are suggesting many and have investigated and actually made a handful work. Are any of these marketable DO any have the software wrappers (in marketable form) ready to go with them?

    A lot of it is and should be just swapping modules in an out of the appliance infrastructure to support the hardware pieces but I think some of it is basic design issues that need to be resolved to see if it can be done with existing hardware and some new or "tweaked" software.

    Questions:
    If you are using remote programming and operation, do you want to have the disclaimer that "in in order to use those feature, you need to include the following code modules in your program. Please read further restriction to using this feature in Appendix C."?
    If we can find a transparent solution that supports native mode programming of a Propeller, is that better? (Bluetooth or Wixel at this point?)

    I'm not trying to be a stick in the mud but as cool as it would be to be able to program and control my ActivityBOT via a 100% WiFi connection from my browser, how much of this is practically in place and doable with what is close to existing now. Yes, is good to have a long term goal and design plan but it's also good to be able to deliver something in the short term which takes me back to my two "customer" letters.

    I'm still working on the Raspi with a modified webIDE and propeller tools loaded on it. I know it's old fashioned but the Props are going to be USB/serial attached first...because that's the only real programming solution Parallax sells and supports through software today and into the near future.
  • David BetzDavid Betz Posts: 14,516
    edited 2013-11-05 08:33
    T Chap wrote: »
    Here is my suggestion. Either a dedicated PC Server compiler programmer, or a dedicated module that can read a text file and compile and program. Then, use a Nordic nRF24L01+ for the communication from the iPad to the Robot. This requires the Apple Authentication IC, and the simplest to implement is the Roving Networks RN42 APL version. I have talked to Apple and Roving about this before and my understanding is that this is ideal for iPad serial i/o. Parallax would have to enroll in the Apple MFI. Which can take weeks or a month. Once enrolled, you can buy the Roving Networks APL products and be up and running with their development board. But, Roving will not set the products without the Apple license.

    As much as a hassle as Apple makes it to get inside their system to get the Authentication IC, it is worth it to get behind the wall. I got enrolled, but it takes some time and effort. Nick at Roving Networks(now Micro) was a great resource for info on how to do this.
    I think the problem is that your second Bluetooth solution isn't possible currently with the iPad and available Bluetooth modules since it requires the support of the Bluetooth SPP profile and that isn't supported by Apple on the iPad. Apple does support the PAN profile though. Are there any inexpensive Bluetooth modules that support the PAN profile that we might be able to use on the ActivityBot side?
  • jazzedjazzed Posts: 11,803
    edited 2013-11-05 08:56
    Nice reality check ;) This is the solution to beat (and/or join).

    It shouldn't be too hard to use the audio link.

    Need to warm up that muli-platform mobile dev system assuming Qt5.2 is app store compliant.

    Rayman wrote: »
    was just googling "ipad school robot" and found this:
    http://appsineducation.blogspot.com/2013/01/idevices-controlling-robots-in-classroom.html where sphero is the first thing they list... Hey, it's not just me...

    I'm thinking you'll want to be able to control your robot with the iPad as well as program it...
    For that to happen, I think you'll need a Bluetooth connection (or maybe wifi).

    Wonder if the iPad is too big to mount right on top of an ActivityBot, like they do with the iPhone...

    RovingNetworks has Bluetooth solutions that work with iPad. I see they've been bought out by MicroChip...
    Unfortunately, looks like you need to register with Apple and buy their authentication chips to make it work:
    http://ww1.microchip.com/downloads/en/DeviceDoc/RN-41_42-APL-PB_v1_2r.pdf

    Actually, the Sphero and company aren't really what I would call "robots"... They're really just remote controlled vehicles...
    But, I think it would be nice to have a product that would let you both remote control and remote program for autonomous operations...
  • Jeff MartinJeff Martin Posts: 758
    edited 2013-11-05 09:50
    jazzed wrote: »
    The thread title is Programming Propellers :)

    I forgot about that other aspect.

    To clarify, though the point is to bring the education experience of the Propeller to the iPad mobile platform, we're not necessarily saying C only and also not saying iPad only. Ideally, it would be a solution that doesn't shut the door on other possibilities, including Spin/PASM and perhaps icon-based programming too.
  • Bill HenningBill Henning Posts: 6,445
    edited 2013-11-05 10:04
    Unfortunately I agree.

    It would be nice though if all those schools/students submitted it as a bug report.
    Don M wrote: »
    Sorry Bill no offense intended but that would be a total waste of time. Apple could care less about such a small audience.
  • David BetzDavid Betz Posts: 14,516
    edited 2013-11-05 10:32
    To clarify, though the point is to bring the education experience of the Propeller to the iPad mobile platform, we're not necessarily saying C only and also not saying iPad only. Ideally, it would be a solution that doesn't shut the door on other possibilities, including Spin/PASM and perhaps icon-based programming too.
    Certainly any solution that would support C/C++ program could just as easily support Spin and PASM as well. I'm not sure that the reverse is true though. For instance, it would probably be relatively easy to get openspin working under iOS but I don't think the same could be said for PropGCC. I might be wrong though. I guess iOS has the same base OS as Mac OS X and PropGCC runs fine there.
  • RaymanRayman Posts: 14,659
    edited 2013-11-05 10:41
    Maybe Parallax could host a server that compiled user code over the web...

    Actually, I think Qt5 was mentioned... Supposedly, that will compile C++ code for iPad and iPhone too, I think...
  • jazzedjazzed Posts: 11,803
    edited 2013-11-05 11:16
    Rayman wrote: »
    Maybe Parallax could host a server that compiled user code over the web...

    Actually, I think Qt5 was mentioned... Supposedly, that will compile C++ code for iPad and iPhone too, I think...

    The problem with having one central server that hosts a compiling service is scalability. How many simultaneous compiles can you host before the system response time becomes unbearable?

    I just can't imagine writing a C (or other text based) program the traditional way on a phone or pad without a keyboard though. You could have a statement-by-statement drag, drop, and manipulate programming environment with canned function/variable names, etc... but I'm not sure that's worth anything.
  • RaymanRayman Posts: 14,659
    edited 2013-11-05 11:49
    Trying to write code on an iPad (without the $60 keyboard) does sound painful...
    But, if you're just doing minor edits to existing code, it maybe wouldn't be that bad...
  • David BetzDavid Betz Posts: 14,516
    edited 2013-11-05 12:15
    Rayman wrote: »
    Trying to write code on an iPad (without the $60 keyboard) does sound painful...
    But, if you're just doing minor edits to existing code, it maybe wouldn't be that bad...
    Yes, minor tweaks would be fairly easy. Also, I think people much younger than myself find it easier to type on touch screens than I do. I think the big problem are the special characters needed for programming. Maybe the iPad language should be Cobol where everything is a keyword and there are no funky curly braces... :-)
  • jmgjmg Posts: 15,173
    edited 2013-11-05 12:40
    Rayman wrote: »
    Well, you're right... Maybe that's not such a bad solution...

    Could suffer from interference though with a lot of them though, right?
    Also, I imagine you'd have to keep the dingus pointed at the robot for it to work...

    Audio-to-infrared link is certainly a good option, that can complement the more complex wireless networks.

    Usually there is a natural location-pairing of the student and their Prop, so a Server that compiled code to an Audio-play file, for upload via infrared could have natural benefits.
    It would fit nicely to download and run use, and need less energy than wireless.

    Obvious next question, is how many of these infrared solutions are two-way links ?
  • Heater.Heater. Posts: 21,230
    edited 2013-11-05 13:09
    Am I losing my mind, or has the world gone crazy?

    On the one hand, students have an iPad. That is a computer perfectly capable of running the Open Source Spin compiler or propgcc. The iPad has enough processing power and memory to handle these kind of jobs with ease along with graphics capabilities well in excess of what is required to run SimpleIDE or many other IDEs.

    On the other hand we have the Propeller which only needs a simple serial link to program it and communicate with it when it is running. Three pieces of wire.

    But, here we are in 2013, with no idea of how to run such simple software on our computers and thinking about how to communicate with our target systems via audio or infrared or WIFI hacks.

    Why?
  • ctwardellctwardell Posts: 1,716
    edited 2013-11-05 13:16
    Heater. wrote: »
    Am I losing my mind, or has the world gone crazy?

    On the one hand, students have an iPad. That is a computer perfectly capable of running the Open Source Spin compiler or propgcc. The iPad has enough processing power and memory to handle these kind of jobs with ease along with graphics capabilities well in excess of what is required to run SimpleIDE or many other IDEs.

    On the other hand we have the Propeller which only needs a simple serial link to program it and communicate with it when it is running. Three pieces of wire.

    But, here we are in 2013, with no idea of how to run such simple software on our computers and thinking about how to communicate with our target systems via audio or infrared or WIFI hacks.

    Why?

    Because Rube Goldberg was ahead of his time.

    C.W.
Sign In or Register to comment.