Blackberry Simulator Network issue on Windows7/64bit/32bit(on vmfusion), what to do? - blackberry

i have Windows 7 64bit on my PC and i have Windows 7 32bit on my vmfusion on mac.
The problem is as follows, if i run early version of blackberry simulators (not touchscreen, but with scroll ball), i do not get network access. I try to run MDS as i have read on forums, but it looks like MDS quits, and i still have no network acess.
The new simulators, let me just run them, and i dont even need to lunch mds, i get access to network with no problem. But the project i am working on, requires me to test mobile site again older blackberry devices.
So here is what i have done so far:
Made sure i have following for java: "C:\Program Files (x86)\Java\jre6" "C:\Program Files (x86)\Java\jdk1.5.0_22" "C:\Program Files (x86)\Java\jre1.5.0_22", do i need anything else?
set up environment path variable to bin folders: C:\Program Files (x86)\Java\jdk1.5.0_22\bin;C:\Program Files (x86)\Java\jre1.5.0_22\bin;
installed everything at separate location as administrator (D:\Programs\Research In Motion), so not to have any write/read issues.
installed MDS and then BlackBerry Smartphone Simulators 4.5.0 - 4.5.0.81 (8100)
now i try to run MDS first, and i see two cmd/three windows popping up one after another, and closing right away. I start up simulator and everything starst great, but when i go to browser and try to navigate to web resource i get an error "Unable to connect to the selected Mobile Data Service, please try again later".
Little edit:
I have moved my effort to XP, which solved MDS start up issue, but simulator still cant establish network connection. See screen shot.

To start MDS you will have to start a console with "Run as administrator" then go to the path where you installed mds and start the .bat file from your elevated console.
Here the console command to start MDS.
EDIT
When MDS is running you can connect to it with your browser to see what is not working
goto : http://localhost:8080/

Related

Xamarin.Forms - Build Errors when trying to deploy to local iOS Device - "The given path's format is not supported"

The Issue
I have a Xamarin.Forms app, which runs fine in Android and iOS Simulators, as well as on a physical Android device.
But when I try to deploy to a local physical iOS device, Visual Studio reports a number of similar build errors, all relating to files that I have in the wwwroot folder.
For example:
Unable to copy file "..\BlazorHybridApp\wwwroot\weather.json" to "C:\Users\JohnDoe\AppData\Local\Temp\Xamarin\HotRestart\Signing\BlazorHybridApp.iOS.app\out\Payload\BlazorHybridApp.iOS.app\D:\Dev\MobileBlazorBindings\BlazorHybridApp\BlazorHybridApp\wwwroot\weather.json". The given path's format is not supported. BlazorHybridApp.iOS
Similarly:
Unable to copy file "..\BlazorHybridApp\wwwroot\css\app.css" to "C:\Users\JohnDoe\AppData\Local\Temp\Xamarin\HotRestart\Signing\BlazorHybridApp.iOS.app\out\Payload\BlazorHybridApp.iOS.app\D:\Dev\MobileBlazorBindings\BlazorHybridApp\BlazorHybridApp\wwwroot\css\app.css". The given path's format is not supported. BlazorHybridApp.iOS
Looking at the error detail, the destination path does appear to be malformed.
Interestingly, some of the files included in the build errors are not in fact referenced anywhere within the program code as it stands (e.g. the weather.json file), and so I'm led to believe it's not a referencing/path issue within the program code itself. It seems sufficient for a file to appear in the wwwroot folder (or one of it's sub-folders) for it to generate a build error, but ONLY when building for a physical iOS device.
The Environment
Mac
I'm including the Mac details for completeness, but it seems the build doesn't get as far as the Mac before stopping with build errors.
Xcode 12.5
Windows
Windows 10
Visual Studio 2019 version 16.10.4
I have disabled "Hot Restart" in Tools > Options > Xamarin > iOS Settings in case it was messing things up.
And the files within the wwwroot folder are set as follows within VS:
Can anyone suggest anything I might try?
I managed to "resolve" the issue myself, well, at least side-step it.
When I was getting the build errors, I was trying to deploy to a physical device connected to my Windows machine.
If instead I connected the device to the Mac, and ran the same build process on Windows, the build completed with no errors.
Another weird quirk of Visual Studio, it would seem.

What is causing this build error targeting iphonesimulator from Visual Studio?

I'm getting these errors, building for any iOS simulator:
C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\MSBuild\Xamarin\iOS\Xamarin.iOS.Common.targets(473,3): error MSB3231: Unable to remove directory "obj\iPhoneSimulator\Debug\". The directory is not empty
OR
SeverityCodeDescriptionProjectFileLineSuppression StateSuppression State Error Unable to remove directory "UserControls". Access to the path 'D:\Projects\Solutions\mycompany\iOS\obj\iPhoneSimulator\Debug\UserControls' is denied.mycompany.iOS
OR both together...
I'm using VS 2019 version 16.3.7 on Windows 10 machine and Xcode 11.2.1 on Mac Mini, OSX 10.14.6 and it does not matter which iOS simulator targeted, all version 13.2.2. Developing a Xamarin Forms application.
If I switch to target one of my hard devices, I get multiple errors like this:
error : Access to the path 'D:\Projects\Solutions\mycompany\iOS\obj\iPhone\Debug\Popups\TemplatePicker.xaml.g.cs' is denied.
I can work around this by quitting VS, removing read-only flag on the obj folder and all it contents, run VS as admin, THEN it builds and pushes to the device.
Switching back to target a simulator, I get the first error again.
Deleting Bin and Obj folders does not help either.
Side note - this was working until Windows rebooted itself on my dev machine, closing VS and forcing recovery of some files. Android version works just fine in simulator and hard device, no issues.
Wondering if I upgrade VS to version 16.4.5 and Xcode to 11.3.1, this might be resolved. Any ideas?
Are these version compatible with the latest VS-Xcode connector? (I've seen issues with version incompatibility) .
Any ideas? Resolutions?
Thank you
OK, here's what I've found...
The connection and link to XCode from VS on the PC causes a lock or some sort when targeting any iOS simulor. This is intermittent but once the locks are imposed, one needs to
close VS
quit the Simulator on the Mac.
delete the Obj and Bin folders in the solution
Re-open VS, open the project, let it sync with the Mac.
Restart Simulator on the mac
Rebuild. This could take a couple iterations too.
If that does not clear the problem, shut down both machines, remember to delete Obj and Bin folders.
Frustrating, slow, but it works for me for now.

Windows Mobile Device Center stops working after "not supported bluetooth function" driver is installed

I run the drvupdate-64 installer which runs until it closes and I get a notification in the tray icon that '"not supported bluetooth function"' was successfully installed as a driver.
I found that a bit weird and after that NOTHING happens with the installer, it just dissapers and doesn't come back.
In task manager I can see it running as 'driver_setup.exe' with the description 'windows mobile device center setup' but that's it, nothing else seems to be happening.
Any ideas what's going wrong and how I can fix this? I need it to get the windows mobile sdk to install.
I had to navigate to the install directory of WMDC Driver Update and find the installer to continue the process, the installer was bugging out on me and not proceeding to the next step for some reason...
I had a similar issue when installing on Dell laptops models 7480, 7280. I had tried updating removing device drivers as per Microsoft Answers with no success.
Having come across the above I did continue the installer process as per tweetypi comment but still had issues. I was able to install and get this working as per following steps:
After running the WMDC installer I could see that in task manager the install process "driver_setup.exe" was still running.
As per tweetypi answers I then navigated to the install directory for WMDC Driver Update to find the installer and continue the process:
C:\Windows\WindowsMobile
I opened each Drivers folder (Bluetooth, RNDIS, Serial) in turn and run the “wmupdate” installer.
Windows Mobile Device Centre was then listed on my programs list but would not launch.
I then opened Device Manager from Control Panel. Changed view to show hidden devices. This revealed 'Bluetooth Virtual Devices' > 'Not Supported Bluetooth function'.
I then uninstalled this driver and checked delete the driver software for this device
After this, I ended the “driver_setup.exe” process within task manager. Then run the “driver_setup.exe” install file once more. The install process was then able to complete and the Windows Mobile Device Centre was now launching.
The device I needed to connect was for USB, I'm not sure about functionality for Bluetooth after removing the virtual device.

Loading BlackBerry application from command line

I am following the instruction from "Using the BlackBerry Smartphone Simulator programmatically" to load a .cod file from the command line using fledgecontroller commands. I am calling LoadCod(D:\Sample.cod) and nothing happens; the application does not install on the simulator. However if I manually browse and load the cod from the simulator's “file->Load Java Program” option.
Do you get any error message at all?
If I try a similar thing (have a cod in C:\Sample.cod, connect using fledge and attempt LoadCod(C:\Sample.cod)) I get the following error message -
Jvm: could not open C:\Program Files\Research In Motion\BlackBerry Smartphone Simulators 4.5.0\4.5.0.55 (8310)\sample.cod
I moved the sample.cod to that directory and it worked okay. If you get no error message I am not sure what the problem is. Are you definitely connected to the correct simulator session? What simulator and OS version are you using?

Blackberry MDS simulator - Can't connect to the internet in the simulator

I'm trying to do some testing of a website through the Blackberry simulator, while the simulator works fine, I can't get to any sites in the Blackberry Browser.
Here is the specific setup I'm using.
I'm Windows 7 (64-bit) Home Edition
I have the latest (at the time) MDS installation - BlackBerry Email and MDS Services Simulators 4.1.4
Finally, I have the latest (at the time) Blackberry Simulator - BlackBerry Smartphone Simulators 5.0.0 (5.0.0.442) - 9700
I first start the MDS service, it briefly pops up the command-prompt and then closes it. I'm assuming that when it does that, it started the MDS service. Then I open the Blackberry simulator (9700), which opens up fine and loads the Blackberry OS. Then with the Blackberry OS all loaded up, I navigate to the browser and for example type www.google.com and then at the bottom it just says "sending request" and loads for about a minute. Then times out and says it can't find a connection.
Anyone have any thoughts on what I'm missing? Or, does anyone know of an online simulator for the Blackberry, because thus far this has been a huge pain for testing sites on a Blackberry.
Thank you!
Ben
I started cmd.exe as "Run as Administrator" and then entered
cd "C:\Program Files\Research In Motion\BlackBerry Email and MDS Services Simulators 4.1.4\MDS"
then
run.bat
and now i have the MDS Simlator 4.1.4 working.
It needs the administrator rights to run
The MDS needs to be open when you want to access internet through your Simulator.
In the run configuration setup activate Launch Mobile Data System Connection Service (MDS-CS) with simulator
If the MDS window closes ( the console app ) this is probably because you have a problem with your JDK installation.
Make sure the JDK is in your windows Path.
Here is a screenshot in eclipse.
alt text http://livinloud.ca/documents/MDS.jpg
This is what I did to solve the problem:
Install from BlackBerry Java Plugin (Eclipse IDE) in the directory other than C (Windows directory). This software package includes eclipse IDE for developing BB application, the BB simulator and MDS
You can run the MDS from this location D:\Eclipse_BB\plugins\net.rim.ejde.componentpack6.0.0_6.0.0.30\components\MDS
Just double click "run.bat" file. Wait until the process is finished. In the end you should get something like this
Now, you can run the simulator from this location
D:\Eclipse_BB\plugins\net.rim.ejde.componentpack6.0.0_6.0.0.30\components\simulator
Just double click "9800.bat". the name of this bat file can vary depends on the simulator type.
If you still can't connect to the internet, the default port of MDS may have been used by another software.
You can test it from your browser by opening this address: http://127.0.0.1:8080/
The normal condition should result in something like this
If this isn't the case, you can try to change the port number by editing "rimpublic.property" file at this location:
D:\Eclipse_BB\plugins\net.rim.ejde.componentpack6.0.0_6.0.0.30\components\MDS\config
Replace "WebServer.listen.port=8080" with "WebServer.listen.port=8000" or other port number (e.g 8081, 8082, etc)
(I'm using the BlackBerry Email and MDS Services Simulator Package version 4.1.4, downloaded from here: https://www.blackberry.com/Downloads/browseSoftware.do. I'm running Windows 7.)
When you click on MDS in your start menu, it's running a batch file: C:\Program Files\Research In Motion\BlackBerry Email and MDS Services Simulators 4.1.4\MDS\run.bat
Edit this file and replace !BMDS_CLASSPATH!;!BMDS_CLASSPATH2! with %BMDS_CLASSPATH%;%BMDS_CLASSPATH2%.
Also, you need to run that batch file as an administrator.
I tried changing the shortcut to run.bat to "Run as administrator", but for some reason that didn't work. I ended up making my own batch file that contains this:
C:
cd "C:\Program Files\Research In Motion\BlackBerry Email and MDS Services Simulators 4.1.4\MDS"
run.bat
I made a shortcut to my batch file and set that shortcut to "Run as administrator". I'm not quite sure why that works, but it does.
The batch file starting the MDS simulator requires the environment variable JAVA_HOME to be set.
If this variable has not been set or does not point to a valid Java installation the MDS Simulator just quits.
It should point to the JDK or JRE installation path - e.g. C:\Program Files\Java\jre6
You can test this on command line by entering set JAVA_HOME=C:\Program Files\Java\jre6 before executing the MDS run.bat
When you start up the MDS simulator it should open a command prompt window and stay open. If it's closing immediately then there is something wrong with your environment - perhaps the Java binaries aren't in your path?
I was trying this on Windows 64-bit and had the same problem - the service would launch and then immediately exit. Turns out the error was caused by being unable to create a /logs directory under C:\Program Files (x86)\Research In Motion\BlackBerry Email and MDS Services Simulators 4.1.2.
My solution was to change the permission on that directory to be "Full Control", then the service can start. If you then restart the Device Simulator you can finally browse the web.
Many hours of peoples life must be wasted trying to figure this one out. I just spent a few so I hope my solution works for you all.
I did the set Environmental Variable thing.
I use 4.1.4 and JDK 1.6 something
WIndows 64bit
Uninstall MDS program from C:\Program Files (86x)
Install elsewhere. I installed on my desktop as administrator.
I don't know if the Environmental Variable thing helped but MDS worked right after I installed administratively on the desktop.
If you started the simulator before starting MDS then it creates some .dmp files that appear to impede the connection between the device simulator and MDS. Try deleting the .dmp files from the simulator directory and see if that helps.
I just spent 2 days trying various of the tips online about MDS (and there are many) but none helped me.
For me, the solution was to turn off network registration upon simulator launch in eclipse.
(posted in case someone with my problem googles to this page)
For those of you who might still have issues, I found this to be the simplest, easiest solution:
Copy the installed MDS folder to somewhere outside of Program Files (e.g. c:\blackberry\mds")
Make sure you have a JAVA_HOME environment variable pointing to the root of the directory where your Java SDK is installed.
follow steps here first: http://supportforums.blackberry.com/t5/Testing-and-Deployment/BlackBerry-MDS-Simulator-does-not-launch/ta-p/446126
then run cmd.exe as Administrator and Go to MDS directory and run the "run.bat" file:
type at cmd prompt,
cd C:\Program Files\Research In Motion\BlackBerry Email and MDS
Services Simulators 4.1.4\MDS
then type,
run.bat
and press enter
The MDS simulator will start running. Then you can open the simulator for the phone and it should work automatically to connect to internet.
I followed all of the above advisals, but MDS didn't still start!
What was wrong? I had installed J2EE (java_ee_sdk-5_01-windows.exe) instead of J2SE (jdk-6u26-windows-i586.exe), with the latter MDS worked properly
This installation lost me one awful day and a terrible night.
I have it working, what I did....
(Windows 7-64bit)
a) confirmed my Java environment vars:
JAVA_HOME=....\Java\jdk1.6.0_24
JDK_DIR=...same...
JDK_ROOT=...same...
JRE_HOME=...\Java\jre6
(different things need different vars...)
b) installed the "BlackBerry_JDE_6.0.0.0.exe" to non-magic location (E:\Emulators)
c) launched the start-menu item "MDS-CS"
The command window stays open, it is logging the comm events.
d) launched the start-menu item "Device Simulator"
The "BlackBerry 9800 Simulator" launched. I then started the browser and connected to "www.google.com"
Everything was launched as a regular user (no admin privs).

Resources