Cross Platform Development

I am looking at using the rPi to write code and debug a project on a TI Launchpad with an ARM M3 chip. Looks like one of the tools I'll need is the lm4flash tool to use the debug interface on the Launchpad to program the flash on the target. I have some instructions on how to do that as follows...

(download lm4flash sources from github) sudo apt-get install libusb-1.0-0-dev make

Then I should be able to flash the target board with a precompiled binary I have. Does anyone see a problem with any of this?

I don't know much about linux. I will need to learn to use an editor for my sources that will then be compiled on the target. Any suggestions?

--

Rick
Reply to
rickman
Loading thread data ...

In an Xwindows environment, I haven't used any editor but 'nedit' on a regular basis for years - it does all I could ask. In a terminal, I find 'nano' to be adequate.

Reply to
ray carter

I quite like gedit as a *nix graphical editor but prefer the fairly ancient microEmacs when working in a console window (my normal way of working).

OTOH vi/vim is hard to beat for doing repetitive changes to a bunch of files: its search&destroy capabilities are excellent.

--
martin@   | Martin Gregorie 
gregorie. | Essex, UK 
 Click to see the full signature
Reply to
Martin Gregorie

Seems fine. You may need to set the permissions on the USB device so a normal user can run the programmer, but for starters 'sudo' to run it as root.

Console:

nano joe and friends (jstar, jpico, jmacs)

probably have the shallowest learning curve.

GUI:

jedit kate geany gedit

The other biggie, Sublime Text, is for Intel machines only (it's closed source). Lime Text is an open source clone, but I don't know how far that's progressed. I haven't tried any of the GUI apps on a Pi so they could be slow etc.

There's also (g)vi(m) and (X)Emacs, but they might be a bit of a shock to the system after coming from Windows. The one thing to be said is most Unix(like) systems will have vi on them, so it can be handy to know a bit to get you out of a hole.

If you need an editor to run on the Cortex M3 then that's another question...

Theo

Reply to
Theo Markettos

Sometimes. I find geany more useful MOST of the time.

I end up editing files 60 miles way across the public internet with them mounted as filesystems via sshfs somehow. Dunno how the magic works, but it does.

Shame windows cant do that, but there is always samba for a local mount, which on 100Mbps is faster than an old IDE disk used to be it feels like...

I have done SMB mounts across the internet in my time, but fast they aint.

--
Everything you read in newspapers is absolutely true, except for the  
rare story of which you happen to have first-hand knowledge. ? Erwin Knoll
Reply to
The Natural Philosopher

I gave that a go, but preferred Code:Blocks. Easier to attach an existing makefile to a project, and then get any compiler errors picked up, allowing clicks to take you to the source. The editor seems to be a bit better, or more Visual Studio like if that's what you are after.

---druck

Reply to
druck

I've been working (coding) with unix/Linux for 20 years. My favorite is Notepad++ (a gpl'd Windows only editor) samba is an option but the last 5 years or so I've been too lazy for setting up samba. I use the ftp-plugin in notepad++. It does sfpt - via ssh. So if you can log in via ssh - you can edit with notepad++ Nothing to set up at all.

Even if he 'real' stuff is vi/emacs/whatever, I still have not found an editor I like better in Linux.

Best shot there is Kate or Gedit. But if you come from windows, Notepad++ is an easy way out. Then you can compile and link via ssh - putty

Beware of overwriting files if you are many working at the same time though

Reply to
Björn Lundin

I am a firm convert to Geany if coding in a GUI.

--
Everything you read in newspapers is absolutely true, except for the  
rare story of which you happen to have first-hand knowledge. ? Erwin Knoll
Reply to
The Natural Philosopher

Thanks for the suggestions. But I don't understand how would I run Notepad++ under Linux? Are you talking about using WINE?

--

Rick
Reply to
rickman

No. You run Notepad++ under Windows. By using the sftp plugin, you browse the files on the pi, and edit them on windows. That is the plugin fetches the file for you to a local cache on the windows box.

You then edit the file, on windows.

When you save, it is automatically transferred to the pi again.

The nice thing is that the pi already has a running ssh server. And sftp uses ssh. So there is NOTHING to setup on the server (pi) side

- it just works.

Otherwise you likely need to set up samba, which provides you with a possibility to map file shares. (drive letters in windoews) But most/some people tend to think it is complicated.

Reply to
Björn Lundin

Looks nice, I think I'll try that. From the site it looks like it supports some kind of function list that I like. Also, it looks like it has at least some support for Ada, which is what I'll use it for.

Thanks

Reply to
Björn Lundin

On Wed, 22 Apr 2015 21:02:10 +0200

But we hasn't Windows.

Reply to
Rob Morley

OK - then I completely misunderstood.

Reply to
Björn Lundin

Who is "we"? I have windows...

--

Rick
Reply to
rickman

I downloaded an SFTP program, WinSCP but I don't have a clue about how to set it up. Any advice?

--

Rick
Reply to
rickman

So do I but the curtains are drawn

--
Everything you read in newspapers is absolutely true, except for the  
rare story of which you happen to have first-hand knowledge. ? Erwin Knoll
Reply to
The Natural Philosopher

Yes. But this is not what I described. The *plugin* to n++ is just that : a *plugin* - not an external program.

Below is for version 4.3.9 which I know is old.

With winscp you hit ctrl+n and you click 'new' Fill in * ip/host name * user (pi) * pwd (raspberry) and click save

you then name the session (defaults to user@ip)

Then, that session name enters a list of all your named sessions. Click it, and press login.

You will get a window with two lists - your local machine to the left, and the pi to the right. You can now drag/drop files between the machines.

The plugin in n++ is similar, in that you save a session/profile, and get a file-tree of the pi. But if you double click files there, you get to *edit* them. in windows. technically after a file transfer, but still.

You should consider winscp as an explorer that can see via ssh/scp. n++ is an editor and its ssh/ftp-plugin shuould be compared to the 'Open' dialog. But it can also see via ssh/scp

Reply to
Björn Lundin

I think you were not very clear on that. Just like now you say "n++" and I have to assume you mean Notepad++. This has been happening a lot where people tell me it would be good to use X as if I know exactly what they mean and where to find it and how to install it.

When I first was told about sudo apt-get install I thought it couldn't be any easier. But there is many a slip betwixt cup and lip. In other words that often doesn't do it for whatever people are telling me about and I have no other info to go on.

Yes, I can read and follow instructions. But I don't have any of this info and don't know where to get it. I'm not even sure how to connect to the rPi. When I am at home the rPi is plugged into the router by Ethernet. My laptop connects via wifi. Do I need to move the Ethernet cable to the laptop to connect them directly?

Ok, that part is like an FTP app.

--

Rick
Reply to
rickman

If you have just one router which handles both wifi and ethernet, then both devices should be getting their IP address from the DHCP server in the router.

The main problem with that is that IP addresses are dynamically assigned, so the IP each box gets probably depends on the order in which they (and any other machines that use the same router, are started up. This isn't a problem when they want to talk to stuff out on the Internet, but it can be a problem when they want to talk to each other. You need to read the manual for your router to see what its options are. For starters, you should be able to point a browser at it and get it to tell you which machines are connected and what IP they have. Once you know the RPi's IP you can connect to it by telling the SSH client on the PC to login to its IP address, e.g. for a command line client it would look like: ssh myuser@192.168.7.5 assuming that the RPI's IP is

192.168.7.5

There is some stuff you can do to the router that will make it always assign the same IP to a machine, but which way works depends on the router's DHCP server software: some can use the computer's hostname while others need to know the MAC address of the computer's network chip.

--
martin@   | Martin Gregorie 
gregorie. | Essex, UK 
 Click to see the full signature
Reply to
Martin Gregorie

Those of us who doesn't. ;-)

Reply to
Rob Morley

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.