As a deployment test, I created a bare-bones C# Mono project in MonoDevelop. It only shows a window. I didn't make any changes to the code after creation.
It installs and runs perfectly fine on Mountain Lion.
When I install and run it on Lion, however, I get the following error:
Process: launchd [329] Path:
/Applications/Test.app/Contents/MacOS/Test Identifier:
com.yourcompany.test Version: ??? (???) Code Type: X86
(Native) Parent Process: launchd [281]
Date/Time: 2013-06-06 16:00:51.919 -0700 OS Version: Mac OS
X 10.7.5 (11G63) Report Version: 9
Interval Since Last Report: 124001 sec Crashes Since Last
Report: 28 Per-App Crashes Since Last Report: 28 Anonymous
UUID: 1AB061C0-779D-43EC-B6D3-E8C6AED2969C
Crashed Thread: Unknown
Exception Type: EXC_BAD_ACCESS (SIGSEGV) Exception Codes:
KERN_INVALID_ADDRESS at 0x000000008fe01030
Backtrace not available
Unknown thread crashed with X86 Thread State (32-bit): eax:
0x00000000 ebx: 0x00000000 ecx: 0x00000000 edx: 0x00000000 edi:
0x00000000 esi: 0x00000000 ebp: 0x00000000 esp: 0x00000000 ss:
0x00000023 efl: 0x00010202 eip: 0x8fe01030 cs: 0x0000001b ds:
0x00000023 es: 0x00000023 fs: 0x00000000 gs: 0x00000000 cr2:
0x8fe01030 Logical CPU: 2
Binary images description not available
External Modification Summary: Calls made by other processes
targeting this process:
task_for_pid: 1
thread_create: 0
thread_set_state: 0 Calls made by this process:
task_for_pid: 0
thread_create: 0
thread_set_state: 0 Calls made by all processes on this machine:
task_for_pid: 113
thread_create: 0
thread_set_state: 0
Model: iMac12,1, BootROM IM121.0047.B1E, 4 processors, Intel Core i7,
2.8 GHz, 8 GB, SMC 1.71f22 Graphics: AMD Radeon HD 6770M, AMD Radeon HD 6770M, PCIe, 512 MB Memory Module: BANK 0/DIMM0, 4 GB, DDR3, 1333
MHz, 0x80AD, 0x484D54333531533642465238432D48392020 Memory Module:
BANK 1/DIMM0, 4 GB, DDR3, 1333 MHz, 0x80AD,
0x484D54333531533642465238432D48392020 AirPort:
spairport_wireless_card_type_airport_extreme (0x168C, 0x9A), Atheros
9380: 4.0.67.5-P2P Bluetooth: Version 4.0.8f17, 2 service, 18 devices,
1 incoming serial ports Network Service: Ethernet, Ethernet, en0
Network Service: Wi-Fi, AirPort, en1 Serial ATA Device: ST31000528AS,
1 TB Serial ATA Device: HL-DT-STDVDRW GA32N USB Device: FaceTime HD
Camera (Built-in), apple_vendor_id, 0x850b, 0xfa200000 / 3 USB Device:
hub_device, 0x0424 (SMSC), 0x2514, 0xfa100000 / 2 USB Device: Dell
USB Mouse, 0x413c (Dell Inc.), 0x3200, 0xfa120000 / 5 USB Device:
BRCM2046 Hub, 0x0a5c (Broadcom Corp.), 0x4500, 0xfa110000 / 4 USB
Device: Bluetooth USB Host Controller, apple_vendor_id, 0x8215,
0xfa111000 / 7 USB Device: hub_device, 0x0424 (SMSC), 0x2514,
0xfd100000 / 2 USB Device: IR Receiver, apple_vendor_id, 0x8242,
0xfd120000 / 4 USB Device: Internal Memory Card Reader,
apple_vendor_id, 0x8403, 0xfd110000 / 3
Any thoughts? As mentioned, everything works fine on Mountain Lion.
I've tested multiple Mountain Lion computers (works fine) and multiple Lion computers (all fail).
Thanks very much
This might be a problem of where you built it: try building it in Lion instead to see if that makes a difference. I've seen problems before when trying to execute a program on an older OS than where it was built.
Related
Assistance in trying to detect when an actual smart-card is inserted into a USB smart-card reader attached to a handheld Android device.
I have an existing (and completely working) instance of the BroadcastReceiver and am successfully detecting when the actual smart-card reader device is connected via the filters of
myFilter.AddAction(UsbManager.ActionUsbDeviceAttached);
myFilter.AddAction(UsbManager.ActionUsbDeviceDetached);
What I am looking for now is when an actual card is inserted or removed from the device.
By using ADB (Android Debug Bridge) program and using the logcat, I can redirect the output to a file to see what is going on such as
adb logcat -c (to clear log)
adb logcat > c:\SomeFolder\MyAndroidLog.txt
Before starting the log above, I have my handheld device ready, the smart-card reader attached. Immediately after that is when I clear the log and start a fresh capture. Then I insert my smart card, wait a few seconds and then stop the log with Ctrl+C. Upon viewing the log, I am getting
--------- beginning of main
10-07 11:43:26.458 827 827 I chatty : uid=1000(system) /system/bin/surfaceflinger expire 14 lines
10-07 11:43:26.459 827 827 I ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasHDRDisplay retrieved: 0
10-07 11:43:26.861 556 556 W hwservicemanager: getTransport: Cannot find entry vendor.qti.hardware.servicetracker#1.0::IServicetracker/default in either framework or device manifest.
10-07 11:43:26.925 556 556 I chatty : uid=1000(system) hwservicemanage identical 14 lines
10-07 11:43:26.928 556 556 W hwservicemanager: getTransport: Cannot find entry vendor.qti.hardware.servicetracker#1.0::IServicetracker/default in either framework or device manifest.
10-07 11:43:26.930 7529 7529 D BoundBrokerSvc: onUnbind: Intent { act=com.google.android.gms.feedback.internal.IFeedbackService dat=chimera-action:com.google.android.gms.feedback.internal.IFeedbackService cmp=com.google.android.gms/.chimera.GmsBoundBrokerService }
10-07 11:43:27.481 827 827 I ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasHDRDisplay retrieved: 0
10-07 11:43:27.483 827 827 I chatty : uid=1000(system) /system/bin/surfaceflinger identical 2 lines
10-07 11:43:27.484 827 827 I ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasHDRDisplay retrieved: 0
10-07 11:43:27.780 1170 1170 I HSMCOUNTER: Wrote to EEPROM: ret: 0
10-07 11:43:28.444 827 827 I ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasHDRDisplay retrieved: 0
So it is showing some context of a ConfigStore, but nothing that indicates the "intent" action that other activities are capturing such as when the USB device is connected such as:
10-07 12:05:15.068 1512 1828 I ActivityManager: START u0 {act=android.hardware.usb.action.USB_DEVICE_ATTACHED flg=0x11000000 cmp=com.gemalto.gempcsc.gempcscserviceactivity/com.gemalto.gempcsc.gempcscservice.USBBroadcastReceiver (has extras)} from uid 1000
Additionally, if there is a generic way to capture ALL intents going on vs having to manually add all filters and not even knowing what they all COULD be, might help me narrow it down.
You need to talk to the reader using the CCID protocol. See my previous answer.
For example (sequence numbers in bold):
Send PC_to_RDR_GetSlotStatus (message 0x65 for slot 0):
-> 65000000000000000000
And receive RDR_to_PC_SlotStatus (message 0x81):
Example response for no card present:
<- 81000000000000020000
Example response for inserted unpowered card
<- 81000000000000010000
Below is a base-64 encoded wireshark USB trace detecting card in a GemPC Twin Reader(decode it to binary file and open it in Wireshark, then right-click any packet and select "Decode As...", change to "USB Device" tab, select "USBCCID" protocol and click "OK"):
-----BEGIN PCAP-NG CAPTURE FILE-----
H4sIAAAAAAAAA+Pi5eWSYWBg8LXRlmIE0v+hACQG4usA8R0GEGBhYGJgZygtTsrNzzNg4ATKsjFA
AEgNiJ0D5X96xcrA/SrFzgvIBmGGA9Pfnpn0/38wM5MCI4Muw8opHskg4dO6rAy9QLu4gGwuBtwg
FYmdg8WumteYdjkzN6HYZaPPClaP0y4mCNWIxMNml7LHFLhdB8S6FiH7aw3ULuWjbCT4iw2nvxZ7
YtoF8xfMrsXH2EjwFxsjzC5WNLsi2HztGRlkGJzzS/NKUouKFQqK8ssyU1JTFJIqFVJKcwuSEwuY
GDjAas8cN7NjhrIDgPpYgOwUZohZrEA2MgDZAQDbbEGJZAIAAA==
-----END PCAP-NG CAPTURE FILE-----
(Note: Sequence numbers in capture file have holes as packets are extracted from a longer dump)
I am working on a webrtc implementation for uwp using the following sdk: https://github.com/webrtc-uwp/webrtc-uwp-sdk/tree/releases/m71
The implementation generally works fine though I am having some issues with call quality when packet loss occurs. What happens is that when a packet or a few packets are lost framerate decreases a lot. Think from 30 FPS to less than 1 FPS. The audio is fine however. This would not be a problem if my client would recover when connection is improved again. However at this moment, if the problem occurs then the video is bad for the rest of the call.
I do not know where the issue might lay. As I understand it webrtc is supposed to compensate for packet loss? I was thinking that the issue might be in the sdk I am using. When I get a videotrack from the other peer I just connect it to a mediaelement in uwp so I do not handle the incoming frames myself. As a side note I have tested to just pause the debugger during a call and this also results in bad framerate both for the remote and local track. However worth to note is that even when my local video gets bad framerate it looks good on the other client. This would indicate that something is not working when playing video from a video track locally.
I include my local sdp just in case it is something wrong with that one:
v=0
o=- 3875426963439162405 2 IN IP4 127.0.0.1
s=-
t=0 0
a=group:BUNDLE 0 1
a=msid-semantic: WMS
m=video 52241 UDP/TLS/RTP/SAVPF 96 98
c=IN IP4 ...MY IP ADRESS...
b=AS:1264
a=rtcp:9 IN IP4 0.0.0.0
... SOME ICE CANDIDATES ...
a=ice-ufrag:6ZNW
a=ice-pwd:1JMvi96Ju3YZCX9S+ChJNH2C
a=fingerprint:sha-256 7B:F5:B5:49:E7:76:54:5F:55:D6:D3:2E:97:38:E0:63:63:5F:2E:53:49:BC:BD:B9:1D:40:45:4B:EC:1E:EE:D4
a=setup:actpass
a=mid:0
a=extmap:2 urn:ietf:params:rtp-hdrext:toffset
a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time
a=extmap:4 urn:3gpp:video-orientation
a=extmap:5 http://www.ietf.org/id/draft-holmer-rmcat-transport-wide-cc-extensions-01
a=extmap:6 http://www.webrtc.org/experiments/rtp-hdrext/playout-delay
a=extmap:7 http://www.webrtc.org/experiments/rtp-hdrext/video-content-type
a=extmap:8 http://www.webrtc.org/experiments/rtp-hdrext/video-timing
a=extmap:10 http://tools.ietf.org/html/draft-ietf-avtext-framemarking-07
a=extmap:9 urn:ietf:params:rtp-hdrext:sdes:mid
a=sendrecv
a=msid:- SELF_VIDEO
a=rtcp-mux
a=rtcp-rsize
a=rtpmap:96 VP8/90000
a=rtcp-fb:96 goog-remb
a=rtcp-fb:96 transport-cc
a=rtcp-fb:96 ccm fir
a=rtcp-fb:96 nack
a=rtcp-fb:96 nack pli
a=rtpmap:98 VP9/90000
a=rtcp-fb:98 goog-remb
a=rtcp-fb:98 transport-cc
a=rtcp-fb:98 ccm fir
a=rtcp-fb:98 nack
a=rtcp-fb:98 nack pli
a=fmtp:98 x-google-profile-id=0
a=ssrc-group:FID 2190372283 111930078
a=ssrc:2190372283 cname:C+phDL3HvwhlyByD
a=ssrc:2190372283 msid: SELF_VIDEO
a=ssrc:2190372283 mslabel:
a=ssrc:2190372283 label:SELF_VIDEO
a=ssrc:111930078 cname:C+phDL3HvwhlyByD
a=ssrc:111930078 msid: SELF_VIDEO
a=ssrc:111930078 mslabel:
a=ssrc:111930078 label:SELF_VIDEO
m=audio 52242 UDP/TLS/RTP/SAVPF 111 103 104 9 102 0 8 106 105 13 110 112 113 126
c=IN IP4 ...MY IP ADRESS...
a=rtcp:9 IN IP4 0.0.0.0
... SOME ICE CANDIDATES ...
a=ice-ufrag:6ZNW
a=ice-pwd:1JMvi96Ju3YZCX9S+ChJNH2C
a=fingerprint:sha-256 7B:F5:B5:49:E7:76:54:5F:55:D6:D3:2E:97:38:E0:63:63:5F:2E:53:49:BC:BD:B9:1D:40:45:4B:EC:1E:EE:D4
a=setup:actpass
a=mid:1
a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level
a=extmap:9 urn:ietf:params:rtp-hdrext:sdes:mid
a=sendrecv
a=msid:- SELF_AUDIO
a=rtcp-mux
a=rtpmap:111 opus/48000/2
a=rtcp-fb:111 transport-cc
a=fmtp:111 minptime=10;useinbandfec=1
a=rtpmap:103 ISAC/16000
a=rtpmap:104 ISAC/32000
a=rtpmap:9 G722/8000
a=rtpmap:102 ILBC/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:106 CN/32000
a=rtpmap:105 CN/16000
a=rtpmap:13 CN/8000
a=rtpmap:110 telephone-event/48000
a=rtpmap:112 telephone-event/32000
a=rtpmap:113 telephone-event/16000
a=rtpmap:126 telephone-event/8000
a=ssrc:2339515350 cname:C+phDL3HvwhlyByD
a=ssrc:2339515350 msid: SELF_AUDIO
a=ssrc:2339515350 mslabel:
a=ssrc:2339515350 label:SELF_AUDIO
Any help or suggestions as to what might be wrong would be greatly appreciated!
Are you sure the framerate decreases to 1fps? That is too low. I would advice you to check the exact framerate with different conditions, this can give you some more detailed information about the issue. You can do it for free in Loadero, here are some resources, that will help you create some free tests to get insights:
A blog post with a guide to testing webRTC apps https://blog.loadero.com/2020/08/10/how-to-set-up-an-automated-webrtc-test-with-loadero/
Info about setting network conditions, packet loss, jitter and more https://wiki.loadero.com/test-creation/participant-configuration/network-conditions
How to use post-run assertions, this will allow you get exact FPS https://blog.loadero.com/2020/01/29/how-to-get-the-best-out-of-post-run-assertions/
Sign up here to run those tests and get detailed data https://loadero.com/home
Running tests with different network conditions will help you get detailed info about which network issues cause the FPS decrease and how much of a decrease that is. Hope this will allow you to find the issue in your application.
I am trying to get the battery level of my headset device with bluetooth 4.1 with AT commands from Windows using the Handsfree Profile (HFP).
I have extracted the bluetooth log from my Android phone (which is able to get the battery level) and the headset is using HFP to send AT command with the battery information (AT+IPHONEACCEV), this is one of the packets extracted from the log (with wireshark):
Frame 1122: 38 bytes on wire (304 bits), 38 bytes captured (304 bits)
Encapsulation type: Bluetooth H4 with linux header (99)
Arrival Time: Jul 16, 2020 12:18:16.449232000 Romance Daylight Time
[Time shift for this packet: 0.000000000 seconds]
Epoch Time: 1594894696.449232000 seconds
[Time delta from previous captured frame: 0.001885000 seconds]
[Time delta from previous displayed frame: 0.018263000 seconds]
[Time since reference or first frame: 21.363811000 seconds]
Frame Number: 1122
Frame Length: 38 bytes (304 bits)
Capture Length: 38 bytes (304 bits)
[Frame is marked: False]
[Frame is ignored: False]
Point-to-Point Direction: Received (1)
[Protocols in frame: bluetooth:hci_h4:bthci_acl:btl2cap:btrfcomm:bthfp]
Bluetooth
[Source: GNAudio_xxxxx (AA:BB:CC:DD:EE:FF)]
[Destination: SamsungE_xxxxx (FF:EE:DD:CC:BB:AA)]
Bluetooth HCI H4
[Direction: Rcvd (0x01)]
HCI Packet Type: ACL Data (0x02)
Bluetooth HCI ACL Packet
Bluetooth L2CAP Protocol
Bluetooth RFCOMM Protocol
Address: E/A flag: 1, C/R flag: 0, Direction: 0, Channel: 2
Control: Frame type: Unnumbered Information with Header check (UIH) (0xef), P/F flag: 0
Payload length: 25
Frame Check Sequence: 0xbf
Bluetooth HFP Profile
[Role: HS - Headset (2)]
AT Stream: AT+IPHONEACCEV=2,1,5,2,0\r
Command 0: +IPHONEACCEV
Command Line Prefix: AT
Command: +IPHONEACCEV (Apple Bluetooth Headset Battery Level Indication)
Type: Action Command (0x003d)
Parameters
Count: 2
Key: Battery Level (1)
Value: 5
Key: Dock State (2)
Value: 0
Now, I am trying to do get this AT commands from the headset in my Windows C# application using the 32feet (InTheHand.Net.Bluetooth) library. To do so I try to connect to the headset using BluetoothService.Handsfree:
BluetoothDevicePicker picker = new BluetoothDevicePicker();
BluetoothDeviceInfo device = await picker.PickSingleDeviceAsync();
BluetoothClient cli = new BluetoothClient();
//device.SetServiceState(BluetoothService.Handsfree, true);
cli.Connect(device.DeviceAddress, BluetoothService.Handsfree);
if (cli.Connected) MessageBox.Show("OK");
NetworkStream stream;
stream = cli.GetStream();
if (stream.CanRead)
{
byte[] buff = new byte[1024];
int n = 0;
StringBuilder str = new StringBuilder();
while (stream.DataAvailable)
{
n = await stream.ReadAsync(buff, 0, buff.Length);
str.AppendFormat("{0}", Encoding.ASCII.GetString(buff, 0, n));
}
MessageBox.Show(str.ToString());
}
When executing the code it gives the following error in cli.Connect(device.DeviceAddress, BluetoothService.Handsfree);:
System.Net.Sockets.SocketException: 'A socket operation failed because the destination host was down'
With cli.Connect(device.DeviceAddress, BluetoothService.SerialPort);it connects (so the host it is not down) but i do not get any reply from the stream.ReadAsync call.
How can i do this? Thanks!
I've found another attempt to implement this: https://github.com/SpartanX1/bluetooth_classic_battery_windows
In the README it says that device should be paired but disconnected. This way when you run the code, socket is able to connect and send/read AT reports. And device is switched to connected state automatically. This works but is absolutely insane.
If device is already connected, socket returns same error (destination host was down).
I have built my first game in Unity called Aesopicas. It runs great on my Mac in Unity's game window, but after I build it to my iPad the game become very slow and crashes. I have basically created 9 different levels by creating level 1 and then tweaking all the other levels slightly. I thinks it's something wrong with memory but I have no idea where to even start. Here is the console message from Xcode:
2019-12-20 23:34:33.181112+0100 Aesopicas[1856:158175] [DYMTLInitPlatform] platform initialization successful
2019-12-20 23:34:33.389544+0100 Aesopicas[1856:157832] Built from '2019.1/staging' branch, Version '2019.1.7f1 (f3c4928e5742)', Build type 'Development', Scripting Backend 'il2cpp'
2019-12-20 23:34:33.419052+0100 Aesopicas[1856:157832] -> registered mono modules 0x10262cc40
-> applicationDidFinishLaunching()
PlayerConnection initialized from /var/containers/Bundle/Application/DE82F3AF-5A93-4309-9E79-166CF7A792FD/Aesopicas.app/Data (debug = 0)
PlayerConnection initialized network socket : 0.0.0.0 55000
Multi-casting "[IP] 192.168.1.177 [Port] 55000 [Flags] 2 [Guid] 1809220790 [EditorId] 3469678780 [Version] 1048832 [Id] iPhonePlayer(Daniels-iPad):56000 [Debug] 0 [PackageName] iPhonePlayer" to [225.0.0.222:54997]...
Started listening to [0.0.0.0:55000]
PlayerConnection already initialized - listening to [0.0.0.0:55000]
2019-12-20 23:34:33.826422+0100 Aesopicas[1856:157832] Metal GPU Frame Capture Enabled
2019-12-20 23:34:33.830255+0100 Aesopicas[1856:157832] Metal API Validation Disabled
-> applicationDidBecomeActive()
GfxDevice: creating device client; threaded=1
Initializing Metal device caps: Apple A7 GPU
Initialize engine version: 2019.1.7f1 (f3c4928e5742)
2019-12-20 23:34:38.049646+0100 Aesopicas[1856:157832] [Common] _BSMachError: port bd03; (os/kern) invalid capability (0x14) "Unable to insert COPY_SEND"
2019-12-20 23:34:38.051391+0100 Aesopicas[1856:157832] [Common] _BSMachError: port bd03; (os/kern) invalid capability (0x14) "Unable to insert COPY_SEND"
UnloadTime: 8.291500 ms
Setting up 1 worker threads for Enlighten.
Thread -> id: 171047000 -> priority: 1
2019-12-20 23:34:40.541065+0100 Aesopicas[1856:158194] [BoringSSL] nw_protocol_boringssl_get_output_frames(1301) [C1.1:2][0x11154a180] get output frames failed, state 8196
2019-12-20 23:34:40.541536+0100 Aesopicas[1856:158194] [BoringSSL] nw_protocol_boringssl_get_output_frames(1301) [C1.1:2][0x11154a180] get output frames failed, state 8196
2019-12-20 23:34:40.544719+0100 Aesopicas[1856:158194] TIC Read Status [1:0x0]: 1:57
2019-12-20 23:34:40.546116+0100 Aesopicas[1856:158194] TIC Read Status [1:0x0]: 1:57
2019-12-20 23:34:41.489586+0100 Aesopicas[1856:158161] [BoringSSL] nw_protocol_boringssl_get_output_frames(1301) [C2.1:2][0x1115589a0] get output frames failed, state 8196
2019-12-20 23:34:41.495355+0100 Aesopicas[1856:158161] [BoringSSL] nw_protocol_boringssl_get_output_frames(1301) [C2.1:2][0x1115589a0] get output frames failed, state 8196
2019-12-20 23:34:41.496473+0100 Aesopicas[1856:158161] TIC Read Status [2:0x0]: 1:57
2019-12-20 23:34:41.496712+0100 Aesopicas[1856:158161] TIC Read Status [2:0x0]: 1:57
2019-12-20 23:34:41.762752+0100 Aesopicas[1856:158194] [BoringSSL] nw_protocol_boringssl_get_output_frames(1301) [C3.1:2][0x11290c790] get output frames failed, state 8196
2019-12-20 23:34:41.763611+0100 Aesopicas[1856:158194] [BoringSSL] nw_protocol_boringssl_get_output_frames(1301) [C3.1:2][0x11290c790] get output frames failed, state 8196
2019-12-20 23:34:41.765555+0100 Aesopicas[1856:158194] TIC Read Status [3:0x0]: 1:57
2019-12-20 23:34:41.765994+0100 Aesopicas[1856:158194] TIC Read Status [3:0x0]: 1:57
Unloading 5 Unused Serialized files (Serialized files now loaded: 0)
UnloadTime: 19.088167 ms
System memory in use before: 66.6 MB.
System memory in use after: 31.8 MB.
Unloading 18 unused Assets to reduce memory usage. Loaded Objects now: 607.
Total: 26.403167 ms (FindLiveObjects: 5.507875 ms CreateObjectMapping: 0.042042 ms MarkObjects: 13.276292 ms DeleteObjects: 7.574125 ms)
Unloading 1 Unused Serialized files (Serialized files now loaded: 0)
UnloadTime: 5.782208 ms
System memory in use before: 36.1 MB.
System memory in use after: 36.1 MB.
Unloading 19 unused Assets to reduce memory usage. Loaded Objects now: 588.
Total: 2.950250 ms (FindLiveObjects: 0.425167 ms CreateObjectMapping: 0.035500 ms MarkObjects: 1.722833 ms DeleteObjects: 0.764625 ms)
Unloading 1 Unused Serialized files (Serialized files now loaded: 0)
UnloadTime: 23.509542 ms
System memory in use before: 35.1 MB.
System memory in use after: 35.1 MB.
Unloading 1 unused Assets to reduce memory usage. Loaded Objects now: 589.
Total: 5.186708 ms (FindLiveObjects: 1.129708 ms CreateObjectMapping: 0.097625 ms MarkObjects: 3.872875 ms DeleteObjects: 0.078333 ms)
Unloading 0 Unused Serialized files (Serialized files now loaded: 0)
UnloadTime: 15.703042 ms
System memory in use before: 35.1 MB.
System memory in use after: 35.1 MB.
Unloading 1 unused Assets to reduce memory usage. Loaded Objects now: 589.
Total: 4.580750 ms (FindLiveObjects: 0.938375 ms CreateObjectMapping: 0.043042 ms MarkObjects: 3.493833 ms DeleteObjects: 0.103708 ms)
Unloading 2 Unused Serialized files (Serialized files now loaded: 0)
WARNING: Shader Unsupported: 'Hidden/PostProcessing/Uber' - Pass '' has no vertex shader
WARNING: Shader Unsupported: 'Hidden/PostProcessing/Uber' - Pass '' has no vertex shader
WARNING: Shader Unsupported: 'Hidden/PostProcessing/FinalPass' - Pass '' has no vertex shader
WARNING: Shader Unsupported: 'Hidden/PostProcessing/FinalPass' - Pass '' has no vertex shader
UnloadTime: 31.216750 ms
System memory in use before: 65.6 MB.
System memory in use after: 61.5 MB.
Unloading 11 unused Assets to reduce memory usage. Loaded Objects now: 1107.
Total: 14.885458 ms (FindLiveObjects: 0.747792 ms CreateObjectMapping: 0.748958 ms MarkObjects: 8.447125 ms DeleteObjects: 4.937375 ms)
2019-12-20 23:35:22.009078+0100 Aesopicas[1856:158229] Compiler failed with XPC_ERROR_CONNECTION_INTERRUPTED
WARNING -> applicationDidReceiveMemoryWarning()
Unloading 2 Unused Serialized files (Serialized files now loaded: 0)
UnloadTime: 93.769542 ms
System memory in use before: 62.4 MB.
System memory in use after: 62.4 MB.
Unloading 30 unused Assets to reduce memory usage. Loaded Objects now: 1127.
Total: 25.216167 ms (FindLiveObjects: 1.501542 ms CreateObjectMapping: 0.222125 ms MarkObjects: 22.520708 ms DeleteObjects: 0.969083 ms)
WARNING -> applicationDidReceiveMemoryWarning()
Unloading 0 Unused Serialized files (Serialized files now loaded: 0)
UnloadTime: 51.854375 ms
System memory in use before: 62.2 MB.
System memory in use after: 62.2 MB.
Unloading 34 unused Assets to reduce memory usage. Loaded Objects now: 1116.
Total: 31.331333 ms (FindLiveObjects: 1.685333 ms CreateObjectMapping: 0.304125 ms MarkObjects: 28.938500 ms DeleteObjects: 0.399167 ms)
WARNING -> applicationDidReceiveMemoryWarning()
Unloading 3 Unused Serialized files (Serialized files now loaded: 0)
UnloadTime: 47.544875 ms
System memory in use before: 97.2 MB.
System memory in use after: 96.9 MB.
Unloading 29 unused Assets to reduce memory usage. Loaded Objects now: 1149.
Total: 32.087625 ms (FindLiveObjects: 1.995542 ms CreateObjectMapping: 0.477167 ms MarkObjects: 27.473792 ms DeleteObjects: 2.138667 ms)
WARNING -> applicationDidReceiveMemoryWarning()
Aesopicas was compiled with optimization - stepping may behave oddly; variables may not be available.
(lldb)
Please check your unity graphic APIs in player settings , mobiles uses GSL2 and GSL3 don’t use Vulkan for simple graphics game since Vulkan is more faster on high-end mobile devices.
Change graphic APIs
Be sure to profile your game to check if the issue related to your level performance
Build the game and see if the issue is still persisting.
In C#, it is possible to retrieve assembly related information like product name, version etc using reflection:
string productName = Assembly.GetCallingAssembly().GetName().Name;
string versionString = Assembly.GetCallingAssembly().GetName().Version.ToString();
How do I do the equivalent if the executing assembly is written in unmanaged C++ (say)? Is it even possible? Assume that I have a .NET dll which is being invoked in unmanaged code via a COM interface.
edit:
To make things absolutely clear, this is my scenario:
I have an executable written in
unmanaged C++
I have a dll written
in C#/.NET
The dll is invoked by the
executable via a COM interface
Within the .NET dll I want to be
able to retrieve information like
the product name and version of the
calling executable.
Possible?
Walking the stack is not necessary to find out what process you are in. You simply make a single Win32 API call:
HMODULE hEXE = GetModuleHandle(NULL);
According to the documentation for this call:
If this parameter is NULL, GetModuleHandle returns a handle to the file used to create the calling process (.exe file).
You can turn this module handle into a filename with GetModuleFileName(), another standard Win32 API. File name in hand, you can then call GetFileVersionInfo() to retrieve the VS_VERSIONINFO structure for that file. The information you want is in there.
Now since you are in .NET you could use P/Invoke signatures for GetModuleHandle(), GetModuleFileName(). For GetFileVersionInfo() you can use System.Diagnostics.FileVersionInfo.
But actually the easiest way to do it is probably to stick with the System.Diagnostics namespace, everything you need is there. Call System.Diagnostics.Process.GetCurrentProcess() to return a Process object for the process you are running in. Then you can retrieve a ProcessModule from the MainModule property. ProcessModule has a property called FileVersionInfo. The information you want is there.
you could use the following code in VB.Net to retrieve extended document properties:
Sub Main()
Dim arrHeaders(41)
Dim shell As New Shell32.Shell
Dim objFolder As Shell32.Folder
objFolder = shell.NameSpace("C:\tmp\")
For i = 0 To 40
arrHeaders(i) = objFolder.GetDetailsOf(objFolder.Items, i)
Next
For Each strFileName In objfolder.Items
For i = 0 To 40
Console.WriteLine(i & vbTab & arrHeaders(i) & ": " & objFolder.GetDetailsOf(strFileName, i))
Next
Next
End Sub
Add a COM reference to Microsoft Shell Controls and Automation to your project to compile.
The output of the above program will be a list of the meta data assigned to all files in C:\tmp such as
0 Name: dpvoice.dll
1 Size: 208 KB
2 Type: Application Extension
3 Date Modified: 14.04.2008 04:41
4 Date Created: 14.04.2008 04:41
5 Date Accessed: 01.12.2008 09:56
6 Attributes: A
7 Status: Online
8 Owner: Administrators
9 Author:
10 Title:
11 Subject:
12 Category:
13 Pages:
14 Comments:
15 Copyright:
16 Artist:
17 Album Title:
18 Year:
19 Track Number:
20 Genre:
21 Duration:
22 Bit Rate:
23 Protected:
24 Camera Model:
25 Date Picture Taken:
26 Dimensions:
27 :
28 :
29 Episode Name:
30 Program Description:
31 :
32 Audio sample size:
33 Audio sample rate:
34 Channels:
35 Company: Microsoft Corporation
36 Description: Microsoft DirectPlay Voice
37 File Version: 5.3.2600.5512
38 Product Name: Microsoftr Windowsr Operating System
39 Product Version: 5.03.2600.5512
40 Keywords:
Let's assume you're after an EXE/DLL's PE header data that #divo's calls return e.g. Company, Product etc... These btw. are derived from calling Win32 Version Info API's - details up on MSDN:
http://msdn.microsoft.com/en-us/library/ms646981.aspx
The next challenge you face is enumerating the callstack to discover your caller's module context. I've not tried - but if you examine your own callstack, I doubt you'll see the unmanaged caller's frames marshalled into there. Suspect it stops at transitional frame injected before switching into the CCW. Also since it's COM, conceivably the caller could call from out of process - your caller would be a proxy process.
If that fails - you'd need the debugging API's to unwind the external stack - that introduces other constraints:
elevated security permissions required to traverse the stack
potential performance impact unwinding the stack.
On a call-by-call basis either of these could make the debugger approach impractical.
Update
Some research indicates there are plenty of bugs and gotchas for reading the stack above the CCW transitional frame even in the debugger. e.g.
http://support.microsoft.com/kb/317221
Mixed Unmanaged/Managed symbol resolution is pretty ugly - some thoughts here on how to do it... DaveBr's blog on debugging is pretty awesome too.
http://bytes.com/groups/net-vc/280340-stackwalk-callstack-symbol-resolve-managed-unmanaged-code-dbghelp-etc
http://blogs.msdn.com/davbr/archive/2005/10/06/478006.aspx
There is plenty of fodder on the steps taken marshalling calls between unmanaged/managed clients - e.g.
http://msdn.microsoft.com/en-us/library/ms973872.aspx